mirror of
https://github.com/luminous-devs/lume.git
synced 2024-09-19 19:46:34 +00:00
updated sql migration
This commit is contained in:
parent
d30d78608f
commit
58fb8e0a33
@ -9,6 +9,10 @@ CREATE TABLE
|
|||||||
updated_at DATETIME NOT NULL DEFAULT CURRENT_TIMESTAMP
|
updated_at DATETIME NOT NULL DEFAULT CURRENT_TIMESTAMP
|
||||||
);
|
);
|
||||||
|
|
||||||
|
-- add default relays
|
||||||
|
-- relay status:
|
||||||
|
-- 0: off
|
||||||
|
-- 1: on
|
||||||
INSERT INTO
|
INSERT INTO
|
||||||
relays (relay_url, relay_status)
|
relays (relay_url, relay_status)
|
||||||
VALUES
|
VALUES
|
||||||
@ -34,6 +38,9 @@ VALUES
|
|||||||
("wss://nos.lol", "1");
|
("wss://nos.lol", "1");
|
||||||
|
|
||||||
-- create accounts
|
-- create accounts
|
||||||
|
-- is_active (part of multi-account feature):
|
||||||
|
-- 0: false
|
||||||
|
-- 1: true
|
||||||
CREATE TABLE
|
CREATE TABLE
|
||||||
accounts (
|
accounts (
|
||||||
id TEXT PRIMARY KEY,
|
id TEXT PRIMARY KEY,
|
||||||
@ -45,6 +52,9 @@ CREATE TABLE
|
|||||||
);
|
);
|
||||||
|
|
||||||
-- create follows
|
-- create follows
|
||||||
|
-- kind (part of multi-newsfeed feature):
|
||||||
|
-- 0: direct
|
||||||
|
-- 1: follow of follow
|
||||||
CREATE TABLE
|
CREATE TABLE
|
||||||
follows (
|
follows (
|
||||||
id INTEGER PRIMARY KEY,
|
id INTEGER PRIMARY KEY,
|
||||||
@ -55,7 +65,7 @@ CREATE TABLE
|
|||||||
);
|
);
|
||||||
|
|
||||||
-- create index for pubkey in follows
|
-- create index for pubkey in follows
|
||||||
CREATE UNIQUE INDEX index_pubkey ON follows (pubkey);
|
CREATE UNIQUE INDEX index_pubkey_on_follows ON follows (pubkey);
|
||||||
|
|
||||||
-- create cache profiles
|
-- create cache profiles
|
||||||
CREATE TABLE
|
CREATE TABLE
|
||||||
@ -74,7 +84,5 @@ CREATE TABLE
|
|||||||
created_at TEXT,
|
created_at TEXT,
|
||||||
kind INTEGER NOT NULL DEFAULT 1,
|
kind INTEGER NOT NULL DEFAULT 1,
|
||||||
tags TEXT NOT NULL,
|
tags TEXT NOT NULL,
|
||||||
content TEXT NOT NULL,
|
content TEXT NOT NULL
|
||||||
relay TEXT,
|
|
||||||
is_multi BOOLEAN DEFAULT 0
|
|
||||||
);
|
);
|
Loading…
Reference in New Issue
Block a user