Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
M
mymusiclist
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
1
Issues
1
List
Board
Labels
Milestones
Wiki
Wiki
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Commits
Issue Boards
Open sidebar
Brian Guadalupe
mymusiclist
Commits
6257f2d2
Commit
6257f2d2
authored
Nov 20, 2017
by
Gink
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Adds fresh copy of db in SQL directory
parent
2afcd314
Changes
4
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
4 additions
and
39 deletions
+4
-39
README.md
README.md
+4
-14
README.txt
SQL/README.txt
+0
-25
freshdb
SQL/freshdb
+0
-0
sqlite3
sqlite3
+0
-0
No files found.
README.md
View file @
6257f2d2
...
...
@@ -29,19 +29,9 @@ This assumes both Python and Git have been already installed and added to the `P
*
`pip install musicbrainzngs`
6.
Make sure that the
`migrations`
folder is empty except for the
`__init__.py`
file
7.
Delete the
`db.sqlite3`
file if it exists
8.
Run the following commands (inside the virtualenv):
*
`python manage.py makemigrations core playlist search tag user`
*
`python manage.py migrate`
9.
Open the
`db.sqlite3`
file in sqlite3, and run the following commands:
*
*`sqlite> `*
`.read SQL/sqlite3.sql`
*
*`sqlite> `*
`.quit`
10.
Populate the songs database
*
Run
`python manage.py shell`
*
~~
*`>>> `*
`exec(open('./SQL/populate_songs.py').read())`
~~ DOESN'T WORK YET!
*
Instead, copy everything from
`populate_songs.py`
and then paste into the shell
*
*`>>> `*
`run()`
*
This works for now...
11.
Run the web server
8.
Get the
`SQL/freshdb`
file then copy it into the root directory
9.
Rename file to db.sqlite3
10.
Run the web server
*
`python manage.py runserver`
1
2
.
(Optional) Create admin account to access the admin interface
1
1
.
(Optional) Create admin account to access the admin interface
*
`python manage.py createsuperuser`
\ No newline at end of file
SQL/README.txt
deleted
100644 → 0
View file @
2afcd314
=========DO NOT RUN===========
mymusiclist.sql
convert
extract.sql
Assuming you have sqlite3 installed and Django setup with migrations,
While in same directory as db.sqlite3, run:
Sqlite3
.open db.sqlite3
.read SQL/sqlite3.sql
If you're not yet migrated, then do this first:
python manage.py makemigrations core
python manage.py migrate
Now you can view tables with .tables and run sql statements
Assuming you have mysql installed, run:
Mysql
Use mymusiclist
Source sql/mysql.sql
SQL/freshdb
0 → 100644
View file @
6257f2d2
File added
sqlite3
deleted
100644 → 0
View file @
2afcd314
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment