diff options
author | Runxi Yu <me@runxiyu.org> | 2025-02-19 21:19:15 +0800 |
---|---|---|
committer | Runxi Yu <me@runxiyu.org> | 2025-02-19 21:19:15 +0800 |
commit | 7fb71b36ad50153f6e05d066284688d1128a7a21 (patch) | |
tree | fbbcc33fdeeb43b1c495baba122a5be845b61ad9 /schema.sql | |
parent | ssh/recv, users, schema: Create pubkey_only users (diff) | |
download | forge-7fb71b36ad50153f6e05d066284688d1128a7a21.tar.gz forge-7fb71b36ad50153f6e05d066284688d1128a7a21.tar.zst forge-7fb71b36ad50153f6e05d066284688d1128a7a21.zip |
ssh/recv, hooks: Create MRs on push, reject pushes to others' MRs
Diffstat (limited to 'schema.sql')
-rw-r--r-- | schema.sql | 8 |
1 files changed, 4 insertions, 4 deletions
@@ -66,14 +66,14 @@ CREATE TABLE sessions ( UNIQUE(user_id, session_id) ); -// TODO: +-- TODO: CREATE TABLE merge_requests ( id INTEGER GENERATED ALWAYS AS IDENTITY PRIMARY KEY, - title TEXT NOT NULL, + title TEXT, repo_id INTEGER NOT NULL REFERENCES repos(id) ON DELETE CASCADE, - creator INTEGER NOT NULL REFERENCES users(id) ON DELETE SET NULL, + creator INTEGER REFERENCES users(id) ON DELETE SET NULL, source_ref TEXT NOT NULL, - destination_branch TEXT NOT NULL, + destination_branch TEXT, status TEXT NOT NULL CHECK (status IN ('open', 'merged', 'closed')), UNIQUE (repo_id, source_ref, destination_branch), UNIQUE (repo_id, id) |