Responsive features graph page

In process of making artists graph maximize height responsively. Moved
misc files in base dir to new scripts dir.
This commit is contained in:
2019-03-07 07:57:15 -05:00
parent dbb1a8738e
commit 91484dbeab
14 changed files with 90 additions and 46 deletions

37
scripts/requirements.txt Normal file
View File

@@ -0,0 +1,37 @@
astroid==2.2.4
certifi==2018.11.29
chardet==3.0.4
defusedxml==0.5.0
Django==2.1.7
django-appconf==1.0.3
django-compressor==2.2
django-crispy-forms==1.7.2
django-filter==2.1.0
django-sass-processor==0.7.2
django-tables2==2.0.5
djangorestframework==3.9.2
et-xmlfile==1.0.1
idna==2.8
isort==4.3.12
jdcal==1.4
lazy-object-proxy==1.3.1
libsass==0.17.0
mccabe==0.6.1
odfpy==1.4.0
openpyxl==2.6.1
psycopg2-binary==2.7.7
pylint==2.3.1
python-dateutil==2.8.0
pytz==2018.9
PyYAML==3.13
rcssmin==1.0.6
requests==2.21.0
rjsmin==1.1.0
six==1.12.0
tablib==0.12.1
typed-ast==1.3.1
unicodecsv==0.14.1
urllib3==1.24.1
wrapt==1.11.1
xlrd==1.2.0
xlwt==1.3.0

15
scripts/reset_db.sh Executable file
View File

@@ -0,0 +1,15 @@
# 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
# INVENV=$(python -c 'import sys; print ("1" if hasattr(sys, "real_prefix") else "0")')
# if $INVENV is 1, then in virtualenv
# echo $INVENV
# if [ $INVENV -eq 1 ]; then
rm login/migrations/0* api/migrations/0*
sudo -u postgres psql -f reset_db.sql
python manage.py makemigrations login api
python manage.py migrate --fake
python manage.py runserver
# fi

3
scripts/reset_db.sql Normal file
View File

@@ -0,0 +1,3 @@
DROP DATABASE spotifyvis;
CREATE DATABASE spotifyvis;
GRANT ALL PRIVILEGES ON DATABASE spotifyvis TO django;

View File

@@ -0,0 +1,14 @@
[Unit]
Description=Update my Spotify listening history.
After=network.target
StartLimitIntervalSec=0
[Service]
Type=simple
Restart=always
RestartSec="15m"
User=kevin
ExecStart=/usr/bin/bash /home/kevin/coding/spotify-lib-vis/src/update-history.sh
[Install]
WantedBy=multi-user.target

3
scripts/update-history.sh Executable file
View File

@@ -0,0 +1,3 @@
#!/bin/bash
/home/kevin/coding/spotify-lib-vis/bin/python /home/kevin/coding/spotify-lib-vis/src/manage.py update-history >> /home/kevin/coding/spotify-lib-vis/src/api/management/commands/update-history.log