-
Notifications
You must be signed in to change notification settings - Fork 5
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #257 from CSHS-CWRA/micromamba
Use mamba-org/provision-with-micromamba Action with caching
- Loading branch information
Showing
1 changed file
with
15 additions
and
16 deletions.
There are no files selected for viewing
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
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -9,7 +9,7 @@ on: | |
jobs: | ||
black: | ||
name: Code linting | ||
runs-on: ubuntu-22.04 | ||
runs-on: ubuntu-latest | ||
steps: | ||
- name: Cancel previous runs | ||
uses: styfle/[email protected] | ||
|
@@ -29,7 +29,7 @@ jobs: | |
pip: | ||
name: Pip with Python${{ matrix.python-version }} | ||
needs: black | ||
runs-on: ubuntu-22.04 | ||
runs-on: ubuntu-latest | ||
strategy: | ||
matrix: | ||
include: | ||
|
@@ -64,35 +64,34 @@ jobs: | |
conda: | ||
name: Conda | ||
needs: black | ||
runs-on: ubuntu-22.04 | ||
runs-on: ubuntu-latest | ||
defaults: | ||
run: | ||
shell: bash -l {0} | ||
steps: | ||
- uses: actions/checkout@v3 | ||
- name: Setup miniconda with mamba | ||
uses: conda-incubator/setup-miniconda@v2 | ||
- name: Setup Conda (Micromamba) with Python3.9 | ||
uses: mamba-org/provision-with-micromamba@main | ||
with: | ||
python-version: "3.9" | ||
miniforge-variant: Mambaforge | ||
channels: conda-forge,defaults | ||
channel-priority: true | ||
activate-environment: ravenpy-env | ||
cache-downloads: true | ||
environment-file: environment.yml | ||
- name: Conda and mamba versions | ||
extra-specs: | | ||
mamba | ||
python="3.9" | ||
- name: Conda and Mamba versions | ||
run: | | ||
conda --version | ||
mamba --version | ||
- name: Install RavenPy | ||
shell: bash -l {0} | ||
run: | | ||
pip install -e ".[dev]" | ||
- name: List installed packages | ||
shell: bash -l {0} | ||
run: | | ||
conda list | ||
- name: Test RavenPy | ||
shell: bash -l {0} | ||
run: | | ||
pytest --cov ravenpy | ||
- name: Report coverage | ||
shell: bash -l {0} | ||
run: coveralls --service=github | ||
env: | ||
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} | ||
|
@@ -103,7 +102,7 @@ jobs: | |
needs: | ||
- pip | ||
- conda | ||
runs-on: ubuntu-22.04 | ||
runs-on: ubuntu-latest | ||
container: python:3-slim | ||
steps: | ||
- name: Coveralls Finished | ||
|