migrations.py 525 B

12345678910111213141516171819202122
  1. versions = [
  2. (
  3. '1',
  4. [
  5. "create table config(name text primary key, value text)",
  6. "insert into config (name, value) values ('version', '1')",
  7. 'create table "station"(remote_id text, indice int, status int)'
  8. ],
  9. ),
  10. (
  11. '2',
  12. [
  13. 'alter table "file" add column "priority" int not null default 0',
  14. ]
  15. ),
  16. (
  17. '3',
  18. [
  19. 'alter table "file" add column "in_server" int not null default 0' ,
  20. ]
  21. )
  22. ]