File tree Expand file tree Collapse file tree 1 file changed +22
-11
lines changed Expand file tree Collapse file tree 1 file changed +22
-11
lines changed Original file line number Diff line number Diff line change 1- #! /bin/bash -xe
1+ #! /bin/bash -e
22
3- conda =" "
4- if $( which mamba)
3+ CONDA =" "
4+ if which mamba > /dev/null
55then
6- conda =$( which mamba)
6+ CONDA =$( which mamba)
77fi
8- if $( which conda)
8+ if which conda > /dev/null
99then
10- conda =$( which conda)
10+ CONDA =$( which conda)
1111fi
12- if [ -z $conda ]
12+
13+ if [ -z $CONDA ]
1314then
1415 echo " Error: conda or mamba is not installed or is not in the PATH."
16+ echo " Go to "
17+ echo " * https://github.com/conda-forge/miniforge (open source)"
18+ echo " * https://www.anaconda.com/download/success (registration required)"
19+ echo " to obtain a conda/mamba installer."
20+ else
21+ echo " Using $CONDA for environment setup"
1522fi
1623
17- echo " using $conda for environment setup"
1824
19- $conda env remove -y -n mellea || true
20- $conda env create -f environment.yml
25+ # note:
26+ # this is a portable way (works in linux and osx) to get the directory of this script.
27+ # readlink -ef may not work on osx.
28+ SCRIPT_DIR=" $( cd " $( dirname " $0 " ) " && pwd) "
29+ $CONDA env create -f $SCRIPT_DIR /environment.yml
30+
31+ $CONDA run -n mellea uv pip install -e .[all] --group dev --group notebook --group docs
2132
22- $conda run -n mellea uv pip install -e .[all] --group dev
33+ $CONDA run -n mellea pre-commit install
You can’t perform that action at this time.
0 commit comments