-
Notifications
You must be signed in to change notification settings - Fork 20
/
Copy pathreload.sh
31 lines (24 loc) · 1.17 KB
/
reload.sh
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
(
echo "DROP database $1 ;";
echo "CREATE DATABASE $1 WITH OWNER $2 ;";
echo "\q";
) | sudo -u postgres psql
rm -f cell_database/migrations/*
touch cell_database/migrations/__init__.py
rm -f cycling/migrations/*
touch cycling/migrations/__init__.py
rm -f filename_database/migrations/*
touch filename_database/migrations/__init__.py
rm -f machine_learning/migrations/*
touch machine_learning/migrations/__init__.py
python3 manage.py makemigrations
python3 manage.py migrate
python3 manage.py edit_database_filename_database --mode add_category
python3 manage.py edit_database_filename_database --mode add_charger_drive_profile
python3 manage.py edit_database_filename_database --mode add_experiment_type
python3 manage.py edit_database_filename_database --mode display --model Category
python3 manage.py edit_database_filename_database --mode display --model ChargerDriveProfile
python3 manage.py edit_database_filename_database --mode display --model ExperimentType
python3 manage.py edit_database_filename_database --mode just_add_files --data_dir=$3
python3 manage.py edit_database_filename_database --mode just_parse_database_files
python3 manage.py import_and_process_raw_neware --DEBUG