-
Notifications
You must be signed in to change notification settings - Fork 1
Expand file tree
/
Copy pathsetup.sh
More file actions
executable file
·38 lines (28 loc) · 953 Bytes
/
setup.sh
File metadata and controls
executable file
·38 lines (28 loc) · 953 Bytes
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
34
35
36
37
38
# Run this script when there is a change to the data/ folder
echo "Setting up database..."
FILES=""
# Drop existing tables
python runSQL.py data/drop_tables.sql
# Books/users/userprogress
python runSQL.py data/books.sql
python runSQL.py data/users.sql
python runSQL.py data/userprogress.sql
python runSQL.py data/user_rating.sql
python runSQL.py data/userlogs.sql
python runSQL.py data/triggers.sql
# Tags
python runSQL.py data/tags/tag.sql
python runSQL.py data/tags/user_book_tag.sql
# Authors
python runSQL.py data/authors/authors.sql
python runSQL.py data/authors/book_authors.sql
# Publishers
python runSQL.py data/publishers/publishers.sql
python runSQL.py data/publishers/book_publishers.sql
# Genre
python runSQL.py data/genres/genre.sql
python runSQL.py data/genres/bookgenre.sql
# Book Club
python runSQL.py data/book_clubs.sql
python runSQL.py data/suggest_club_setup.sql
echo "Database setup complete, check tables on postgresSQL"