-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathstart_tutorial.sh
executable file
·33 lines (27 loc) · 1.12 KB
/
start_tutorial.sh
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
#!/bin/sh
# Stop on problems.
set -e
cd "$(dirname "$0")"
# Target git master using BIOBLEND_TARGET=git+git://github.com/galaxyproject/bioblend.git@master start_tutorial.sh
BIOBLEND_TARGET="${BIOBLEND_TARGET:-bioblend}"
test -z "$VIRTUAL_ENV" || deactivate || true
if [ ! -d .venv ]; then
# If python is from Conda, make sure virtualenv comes from conda-forge
if python -V 2>&1 | grep -q -e 'Anaconda' -e 'Continuum Analytics' || \
python -c 'import sys; print(sys.version.replace("\n", " "))' | grep -q -e 'packaged by conda-forge' ; then
conda install --yes --channel conda-forge 'virtualenv>=16'
fi
if ! command -v virtualenv >/dev/null; then
echo "virtualenv not found, please install it."
echo "For Debian/Ubuntu, this can be accomplished with:"
echo ""
echo " sudo apt install virtualenv"
exit 1
fi
virtualenv .venv
fi
. .venv/bin/activate
python -c 'import sys; sys.version_info >= (2, 7, 9) or sys.exit(1)' || pip install --upgrade --force-reinstall requests[security]
pip install --upgrade "$BIOBLEND_TARGET"
pip install jupyter
jupyter notebook