Refresh CI: add conda/mamba environment file and modern env creation, fix tests, and add modern Github Action workflow file #42
Workflow file for this run
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: build ⚙️ | |
on: | |
push: | |
branches: | |
- master | |
pull_request: | |
branches: | |
- master | |
schedule: | |
- cron: '30 5 * * *' | |
jobs: | |
build: | |
runs-on: ubuntu-latest | |
strategy: | |
matrix: | |
python-version: ["3.8", "3.9", "3.10", "3.11", "3.12"] | |
steps: | |
- uses: actions/checkout@v4 | |
- name: Install packages | |
run: | | |
sudo apt-get -y install pandoc | |
if: matrix.python-version == 3.10 | |
- name: Set up Python ${{ matrix.python-version }} | |
uses: actions/setup-python@v2 | |
with: | |
python-version: ${{ matrix.python-version }} | |
- name: Install requirements 📦 | |
run: | | |
python -m pip install --upgrade pip | |
pip install -e ".[dev]" | |
- name: Test with pytest ⚙️ | |
run: make test-all | |
- name: Lint with flake8 ⚙️ | |
run: make lint | |
if: matrix.python-version == 3.10 | |
- name: Test notebooks ⚙️ | |
run: make test-nb | |
if: matrix.python-version == 3.10 | |
- name: Build docs 🏗️ | |
run: make docs | |
if: matrix.python-version == 3.10 |