Skip to content

Commit a5544fa

Browse files
authoredJan 31, 2023
Merge pull request #245 from imagej/use-mambaforge-and-caching
Build system improvements
2 parents deea507 + 09a188c commit a5544fa

File tree

2 files changed

+13
-3
lines changed

2 files changed

+13
-3
lines changed
 

‎.github/workflows/build.yml

+12-2
Original file line numberDiff line numberDiff line change
@@ -82,18 +82,28 @@ jobs:
8282
shell: bash -l {0}
8383
steps:
8484
- uses: actions/checkout@v2
85+
- name: Cache conda
86+
uses: actions/cache@v2
87+
env:
88+
# Increase this value to reset cache if etc/example-environment.yml has not changed
89+
CACHE_NUMBER: 0
90+
with:
91+
path: ~/conda_pkgs_dir
92+
key:
93+
${{ runner.os }}-conda-${{ env.CACHE_NUMBER }}-${{
94+
hashFiles('etc/example-environment.yml') }}
8595
- uses: conda-incubator/setup-miniconda@v2
8696
with:
8797
# Create env with dev packages
8898
auto-update-conda: true
8999
python-version: 3.9
100+
miniforge-variant: Mambaforge
90101
environment-file: dev-environment.yml
91-
# Activate scyjava-dev environment
102+
# Activate pyimagej-dev environment
92103
activate-environment: pyimagej-dev
93104
auto-activate-base: false
94105
# Use mamba for faster setup
95106
use-mamba: true
96-
mamba-version: "*"
97107
- name: Test pyimagej
98108
run: |
99109
bin/test.sh tests --cov-report=xml --cov=.

‎.pre-commit-config.yaml

+1-1
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@ repos:
1010
- id: flake8
1111
additional_dependencies: [flake8-typing-imports==1.7.0]
1212
- repo: https://github.com/PyCQA/isort
13-
rev: 5.10.1
13+
rev: 5.12.0
1414
hooks:
1515
- id: isort
1616
- repo: https://github.com/psf/black

0 commit comments

Comments
 (0)
Please sign in to comment.