Skip to content

Commit

Permalink
[CI] Fix caching the env in between jobs (#280)
Browse files Browse the repository at this point in the history
  • Loading branch information
blefaudeux authored Apr 21, 2022
1 parent cbcba58 commit ad94fd1
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions .circleci/config.yml
Original file line number Diff line number Diff line change
Expand Up @@ -63,7 +63,7 @@ setup_conda: &setup_conda
source $BASH_ENV
# check if we have restored venv cache (/home/circleci/venv) correctly, if so, just skip
if [ -f /home/circleci/venv/check_version.py ]; then python3 /home/circleci/venv/check_version.py torch gt 1.12 && exit 0; fi
if [ -f /home/circleci/venv/check_version.py ]; then $CONDA_PYTHON /home/circleci/venv/check_version.py torch gt 1.11 && exit 0; fi
hash -r
wget https://repo.continuum.io/miniconda/Miniconda3-latest-Linux-x86_64.sh -O miniconda.sh
Expand All @@ -81,7 +81,7 @@ install_dep: &install_dep
source $BASH_ENV
# check if we have restored venv cache (/home/circleci/venv) correctly, if so, just skip
if [ -f /home/circleci/venv/check_version.py ]; then $CONDA_PYTHON /home/circleci/venv/check_version.py torch gt 1.12 && exit 0; fi
if [ -f /home/circleci/venv/check_version.py ]; then $CONDA_PYTHON /home/circleci/venv/check_version.py torch gt 1.11 && exit 0; fi
# start installing
source activate /home/circleci/venv
Expand All @@ -98,7 +98,7 @@ install_dep_exp: &install_dep_exp
source $BASH_ENV
# check if we have restored venv cache (/home/circleci/venv) correctly, if so, just skip
if [ -f /home/circleci/venv/check_version.py ]; then $CONDA_PYTHON /home/circleci/venv/check_version.py torch gt 1.12 && exit 0; fi
if [ -f /home/circleci/venv/check_version.py ]; then $CONDA_PYTHON /home/circleci/venv/check_version.py torch gt 1.11 && exit 0; fi
# start installing
source activate /home/circleci/venv
Expand Down

0 comments on commit ad94fd1

Please sign in to comment.