internal/store/migrations/0063_push_tokens.up.sql

28e72be7ab6bc96868893853fd8d210c3656960f
gitbay/internal/store/migrations/0063_push_tokens.up.sql

10 lines · 482 bytes

 1-- One row per receive-pack in flight. The hook names its push by the
 2-- token; hookd answers only a live one. Only the SHA-256 is stored.
 3CREATE TABLE push_tokens (
 4    token_hash TEXT PRIMARY KEY,
 5    repo_id    INTEGER NOT NULL REFERENCES repos(id) ON DELETE CASCADE,
 6    user_id    INTEGER NOT NULL REFERENCES users(id) ON DELETE CASCADE,
 7    scope      TEXT NOT NULL,
 8    created_at TEXT NOT NULL DEFAULT (strftime('%Y-%m-%dT%H:%M:%fZ','now')),
 9    expires_at TEXT NOT NULL
10);
Keyboard shortcuts

Global

⌘K
Command palette & jump
/
Focus search
?
Show this help
g d
Dashboard
g e
Explore repositories
g n
Notifications

Repository & editor

t
Find file in repository
y
Copy immutable SHA permalink
g c
Code tab
g i
Issues tab
g m
Merge requests tab
g b
Builds tab
⌘↵
Submit active form