File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -65,10 +65,10 @@ jobs:
6565 key : ${{ runner.os }}-rmgpy-${{ hashFiles('ARC/devtools/install_rmg.sh') }}
6666 restore-keys : ${{ runner.os }}-rmgpy-
6767
68- - name : Install all extras
68+ - name : Install all extras - CI
6969 shell : micromamba-shell {0}
7070 working-directory : ARC
71- run : bash devtools/install_all.sh --no-clean
71+ run : make install-ci
7272
7373 - name : Run Unit Tests
7474 shell : micromamba-shell {0}
Original file line number Diff line number Diff line change 77DEVTOOLS_DIR := devtools
88
99.PHONY : all help clean test test-unittests test-functional test-all \
10- install-all install-molecule install-rmgdb install-autotst install-gcn \
10+ install-all install-ci install- molecule install-rmgdb install-autotst install-gcn \
1111 install-gcn-cpu install-kinbot install-sella install-xtb install-torchani install-ob \
1212 lite check-env compile
1313
2525 @echo " "
2626 @echo " Installation:"
2727 @echo " install Install all external dependencies"
28+ @echo " install-ci Install all external dependencies for CI (no clean)"
2829 @echo " install-molecule Install molecule"
2930 @echo " install-rmgdb Install RMG-database"
3031 @echo " install-autotst Install AutoTST"
@@ -62,6 +63,10 @@ install:
6263 @echo " Installing all external ARC dependencies..."
6364 bash $(DEVTOOLS_DIR ) /install_all.sh
6465
66+ install-ci :
67+ @echo " Installing all external ARC dependencies for CI (no clean)..."
68+ bash $(DEVTOOLS_DIR ) /install_all.sh --no-clean
69+
6570install-molecule :
6671 bash $(DEVTOOLS_DIR ) /install_molecule.sh
6772
Original file line number Diff line number Diff line change @@ -62,18 +62,26 @@ export RMG_PY_PATH="$(realpath RMG-Py)"
6262export RMG_DB_PATH=" $( realpath RMG-database) "
6363
6464# ##############################################################################
65- # CREATE ENVIRONMENT
65+ # CREATE OR UPDATE rmg_env
6666# ##############################################################################
6767cd " $RMG_PY_PATH "
68- echo " 📚 Creating conda env: $ENV_NAME "
69- $COMMAND env create -n " $ENV_NAME " -f environment.yml || {
70- echo " ⚠️ Environment likely exists; trying update..."
68+ echo " 📚 Ensuring conda env: $ENV_NAME "
69+
70+ if $COMMAND env list | grep -qE " ^$ENV_NAME \s" ; then
71+ echo " 📦 Updating existing env…"
7172 if [[ " $COMMAND " == micromamba ]]; then
72- micromamba env update -n " $ENV_NAME " --file environment.yml
73+ $COMMAND env update -n " $ENV_NAME " --file environment.yml
7374 else
7475 $COMMAND env update -n " $ENV_NAME " -f environment.yml
7576 fi
76- }
77+ else
78+ echo " 📦 Creating env from scratch…"
79+ if [[ " $COMMAND " == micromamba ]]; then
80+ $COMMAND env create -n " $ENV_NAME " --file environment.yml
81+ else
82+ $COMMAND env create -n " $ENV_NAME " -f environment.yml
83+ fi
84+ fi
7785
7886# ##############################################################################
7987# COMPILE RMG
You can’t perform that action at this time.
0 commit comments