Fix things

This commit is contained in:
Jan Tuomi
2017-09-15 20:11:44 +03:00
parent 84ca084533
commit 12027a5a80
4 changed files with 40 additions and 18 deletions
+13 -4
View File
@@ -6,10 +6,17 @@ echo "========================================================="
echo "Dependencies: postgresql>9.5, python>3.5"
INTERACTIVE="true"
USE_NPM="true"
if [[ $* == *--no-input* ]]
then
INTERACTIVE="false"
fi
if [[ $* == *--no-npm* ]]
then
USE_NPM="false"
fi
$INTERACTIVE || echo "Running in non-interactive mode." && env
$INTERACTIVE && read -p "Are these programs installed? [y/n]" -n 1 -r || REPLY="y"
echo ""
@@ -56,11 +63,13 @@ then
fi
set -e
(set -x; pip install -r requirements.txt)
(set -x; npm install)
(set -x; python manage.py migrate)
(set -x; python manage.py createdefaultadmin)
set -x
pip install -r requirements.txt
$USE_NPM && npm install
python manage.py migrate
python manage.py createdefaultadmin
set +e
set +x
echo "Done."
echo "Run 'python manage.py runserver 0.0.0.0:8000' to start the development server!"