mirror of
https://github.com/Dvorinka/swingmusic-extended.git
synced 2026-06-03 20:13:02 +00:00
feat: add migration to move old files to xdg directory
+ add db column for migration version + handle pre-init migrations + handle post-init migration
This commit is contained in:
@@ -69,3 +69,13 @@ CREATE TABLE IF NOT EXISTS folders (
|
||||
trackcount integer NOT NULL
|
||||
);
|
||||
"""
|
||||
|
||||
CREATE_MIGRATIONS_TABLE = """
|
||||
CREATE TABLE IF NOT EXISTS migrations (
|
||||
id integer PRIMARY KEY,
|
||||
pre_init_version integer NOT NULL DEFAULT 0,
|
||||
post_init_version integer NOT NULL DEFAULT 0
|
||||
);
|
||||
|
||||
INSERT INTO migrations (pre_init_version, post_init_version) VALUES (0, 0);
|
||||
"""
|
||||
|
||||
Reference in New Issue
Block a user