Skip to content

Commit dcdf381

Browse files
committed
fix: clean up environment cache
1 parent 7cef99c commit dcdf381

File tree

1 file changed

+8
-20
lines changed

1 file changed

+8
-20
lines changed

.circleci/config.yml

Lines changed: 8 additions & 20 deletions
Original file line numberDiff line numberDiff line change
@@ -12,9 +12,9 @@ jobs:
1212
- checkout
1313
- restore_cache:
1414
keys:
15-
- env-v3-{{ .Branch }}-
16-
- env-v3-master-
17-
- env-v3-
15+
- env-v5-{{ .Branch }}-
16+
- env-v5-master-
17+
- env-v5-
1818
- run:
1919
name: Setup git-annex
2020
command: |
@@ -29,17 +29,14 @@ jobs:
2929
- run:
3030
name: Setup DataLad
3131
command: |
32-
export PY3=$(pyenv versions | grep '3\.' |
33-
sed -e 's/.* 3\./3./' -e 's/ .*//')
34-
pyenv local $PY3
35-
python -m pip install --no-cache-dir -U pip "setuptools >= 45.0" "setuptools_scm[toml] >= 3.4"
36-
python -m pip install --no-cache-dir -U datalad datalad-osf
32+
python3 -m pip install --no-cache-dir -U pip "setuptools >= 45.0" "setuptools_scm[toml] >= 3.4"
33+
python3 -m pip install --no-cache-dir -U datalad datalad-osf
3734
3835
- save_cache:
39-
key: env-v3-{{ .Branch }}-{{ .BuildNum }}
36+
key: env-v5-{{ .Branch }}-{{ .BuildNum }}
4037
paths:
4138
- /opt/circleci/git-annex.linux
42-
- /opt/circleci/.pyenv/versions/3.9.4
39+
- /opt/circleci/.pyenv/versions/3.12.2
4340

4441
- restore_cache:
4542
keys:
@@ -49,10 +46,7 @@ jobs:
4946
- run:
5047
name: Install test data from GIN
5148
command: |
52-
export PY3=$(pyenv versions | grep '3\.' |
53-
sed -e 's/.* 3\./3./' -e 's/ .*//')
54-
pyenv local $PY3
55-
export PATH=/opt/circleci/git-annex.linux:$PATH
49+
export PATH=/opt/circleci/.pyenv/versions/3.12.2/bin/:/opt/circleci/git-annex.linux:$PATH
5650
mkdir -p /tmp/data
5751
cd /tmp/data
5852
datalad install -r https://gin.g-node.org/oesteban/nitransforms-tests
@@ -98,9 +92,6 @@ jobs:
9892
name: Build Docker image & push to registry
9993
no_output_timeout: 60m
10094
command: |
101-
export PY3=$(pyenv versions | grep '3\.' |
102-
sed -e 's/.* 3\./3./' -e 's/ .*//')
103-
pyenv local $PY3
10495
e=1 && for i in {1..5}; do
10596
docker build --rm --cache-from=nitransforms:latest \
10697
-t nitransforms:latest \
@@ -123,9 +114,6 @@ jobs:
123114
- run:
124115
name: Check version packaged in Docker image
125116
command: |
126-
export PY3=$(pyenv versions | grep '3\.' |
127-
sed -e 's/.* 3\./3./' -e 's/ .*//')
128-
pyenv local $PY3
129117
THISVERSION=${CIRCLE_TAG:-$(python3 setup.py --version)}
130118
INSTALLED_VERSION=$(\
131119
docker run -it --rm --entrypoint=python nitransforms \

0 commit comments

Comments
 (0)