Skip to content

Commit

Permalink
Use environment file for dependencies in setup-miniconda action
Browse files Browse the repository at this point in the history
  • Loading branch information
mdpiper committed Dec 14, 2023
1 parent 14beaaa commit 90324ab
Show file tree
Hide file tree
Showing 3 changed files with 13 additions and 16 deletions.
7 changes: 5 additions & 2 deletions .github/workflows/black.yml
Original file line number Diff line number Diff line change
Expand Up @@ -17,5 +17,8 @@ jobs:
- uses: actions/checkout@v4
- uses: actions/setup-python@v4
- uses: psf/black@stable
with:
args: ". --check"

- name: Format
run: |
pip install black
black .
9 changes: 4 additions & 5 deletions .github/workflows/docs.yml
Original file line number Diff line number Diff line change
Expand Up @@ -36,23 +36,22 @@ jobs:
steps:
- uses: actions/checkout@v4

- uses: conda-incubator/setup-miniconda@v2
- uses: conda-incubator/setup-miniconda@v3
with:
auto-update-conda: true
python-version: "3.11"
environment-file: environment.yml
mamba-version: "*"
channels: conda-forge,defaults
channel-priority: true

- name: Install requirements
- name: Show conda installation info
run: |
mamba install --file=requirements.txt --file=requirements-docs.txt
mamba info
mamba list
- name: Install package
run: |
pip install -e .
make install
- name: Build documentation
run: |
Expand Down
13 changes: 4 additions & 9 deletions .github/workflows/test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -20,15 +20,15 @@ jobs:
strategy:
matrix:
os: [ubuntu-latest, macos-latest, windows-latest]
python-version: ["3.9", "3.10", "3.11"]
python-version: ["3.9", "3.10", "3.11", "3.12"]

steps:
- uses: actions/checkout@v4

- uses: conda-incubator/setup-miniconda@v2
- uses: conda-incubator/setup-miniconda@v3
with:
auto-update-conda: true
python-version: ${{ matrix.python-version }}
environment-file: environment.yml
mamba-version: "*"
channels: conda-forge,defaults
channel-priority: true
Expand All @@ -38,14 +38,9 @@ jobs:
mamba info
mamba list
- name: Install requirements
run: |
mamba install --file=requirements.txt --file=requirements-testing.txt
mamba list
- name: Build and install package
run: |
pip install -e .
make install
- name: Test
run: |
Expand Down

0 comments on commit 90324ab

Please sign in to comment.