Skip to content

Commit

Permalink
Change how we activate/deactivate for conda envs
Browse files Browse the repository at this point in the history
  • Loading branch information
holdenk committed Mar 23, 2017
1 parent 57a1f6e commit 6f33633
Showing 1 changed file with 9 additions and 1 deletion.
10 changes: 9 additions & 1 deletion dev/run-pip-tests
Original file line number Diff line number Diff line change
Expand Up @@ -83,11 +83,12 @@ for python in "${PYTHON_EXECS[@]}"; do
rm -rf "$VIRTUALENV_PATH"
if [ -n "$USE_CONDA" ]; then
conda create -y -p "$VIRTUALENV_PATH" python=$python numpy pandas pip
source activate "$VIRTUALENV_PATH"
else
mkdir -p "$VIRTUALENV_PATH"
virtualenv --python=$python "$VIRTUALENV_PATH"
source "$VIRTUALENV_PATH"/bin/activate
fi
source "$VIRTUALENV_PATH"/bin/activate
# Upgrade pip & friends if using virutal env
if [ ! -n "USE_CONDA" ]; then
pip install --upgrade pip pypandoc wheel numpy
Expand Down Expand Up @@ -123,6 +124,13 @@ for python in "${PYTHON_EXECS[@]}"; do

cd "$FWDIR"

# conda / virtualenv enviroments need to be deactivated differently
if [ -n "$USE_CONDA" ]; then
source deactivate
else
deactivate
fi

done
done

Expand Down

0 comments on commit 6f33633

Please sign in to comment.