Graphs and tables for your Spotify account.
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 
 
 
 
 

14 lines
468 B

# check if in virtual environment
# https://stackoverflow.com/questions/15454174/how-can-a-shell-function-know-if-it-is-running-within-a-virtualenv/15454916
python -c 'import sys; print(sys.real_prefix)' 2>/dev/null && INVENV=1 || INVENV=0
# echo $INVENV
# if $INVENV is 1, then in virtualenv
if [ $INVENV -eq 1 ]; then
rm spotifyvis/migrations/00*
sudo -u postgres psql -f reset_db.sql
python manage.py makemigrations
python manage.py migrate
fi