blob: fbb13e7d0fefcbd9e0de9af206ec6f67932ab9f7 (
plain)
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 -e
HERE=$(dirname $(readlink -f $0))
cd $HERE
# python-ldap 3.3.1 is going to trigger
# a build, so need to support it
sudo apt install -y -f libpython-dev libldap2-dev libsasl2-dev
SKIP_LINT="${SKIP_LINT-1}"
VENV_DIR="${VENV_DIR-$HERE/.venv}"
if [ ! -f /usr/bin/virtualenv ] ; then
echo "installing python-virutalenv"
sudo apt-get install -y -f python-virtualenv
fi
if [ -z $VIRTUAL_ENV ] ; then
echo "creating venv: $VENV_DIR ..."
virtualenv --python=`which python2` $VENV_DIR
. $VENV_DIR/bin/activate
pip install -r requirements.txt
fi
rm -rf staticroot/*
if [ ! -f "linaro_ldap.py" ];
then
wget -O linaro_ldap.py https://git.linaro.org/infrastructure/linaro-git-tools.git/plain/linaro_ldap.py
fi
DJANGO_SETTINGS_MODULE=settings SKIP_LINT=$SKIP_LINT ./manage.py collectstatic --no-input
DJANGO_SETTINGS_MODULE=settings SKIP_LINT=$SKIP_LINT ./manage.py test license_protected_downloads
|