123456789101112131415161718192021222324 |
- #!/bin/bash
- #
- echo "* Initialising Submodules"
- git submodule init
- git submodule update
-
- echo "* Creating virtual env"
- BASEPATH=`realpath $(dirname $0)`
-
- python3 -m venv $BASEPATH/venv
- $BASEPATH/venv/bin/pip install --upgrade pip
- find $BASEPATH -name requirements.txt | xargs -L 1 $BASEPATH/venv/bin/pip install -r
- $BASEPATH/venv/bin/pip list --outdated --format=json | jq -r '.[] | .name'|xargs -n1 $BASEPATH/venv/bin/pip install -U
-
- echo "* Linking pylibs to venv"
- for path in `find pylibs/ -maxdepth 1 -type d`; do
- if [[ $path != "pylibs/" ]];then
- lib=${path#*/}
- echo Creating symbolic link for library $lib
- rm -f venv/lib/python*/site-packages/$lib
- ln -s ../../../../$path venv/lib/python*/site-packages/
- fi
- done
|