diff options
| author | grm <grm@eyesin.space> | 2026-09-18 14:35:59 +0300 |
|---|---|---|
| committer | grm <grm@eyesin.space> | 2026-09-18 14:36:17 +0300 |
| commit | 7ac90f8e99dbf763b0fe04a17d7eef19dd22cae8 (patch) | |
| tree | fa2409b9c201a27e19a64afcdd5057eeba0a61ac /internal/db/migrations | |
| parent | 0fc470a8d588cac1a51cc4b3e1a2237dc56041c9 (diff) | |
| download | blogspace-7ac90f8e99dbf763b0fe04a17d7eef19dd22cae8.tar.gz blogspace-7ac90f8e99dbf763b0fe04a17d7eef19dd22cae8.tar.bz2 blogspace-7ac90f8e99dbf763b0fe04a17d7eef19dd22cae8.zip | |
Revert "Special pages: a gallery page of the blog's images"
This reverts commit 0fc470a. The feature was not wanted. Migration
00013 stays on disk because databases have already run it (goose refuses
a missing applied migration); 00014 drops the column and table it added.
Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01Sd8UPWrvyYCLj97JexNw3A
Diffstat (limited to 'internal/db/migrations')
| -rw-r--r-- | internal/db/migrations/blog/00014_drop_page_kind.sql | 15 |
1 files changed, 15 insertions, 0 deletions
diff --git a/internal/db/migrations/blog/00014_drop_page_kind.sql b/internal/db/migrations/blog/00014_drop_page_kind.sql new file mode 100644 index 0000000..1bbf493 --- /dev/null +++ b/internal/db/migrations/blog/00014_drop_page_kind.sql @@ -0,0 +1,15 @@ +-- +goose Up +-- Special pages (00013) were dropped before release: the kind column and the +-- hidden-files table go, the migration stays so databases that ran it still +-- match the chain. +DROP TABLE page_hidden_files; +ALTER TABLE pages DROP COLUMN kind; + +-- +goose Down +ALTER TABLE pages ADD COLUMN kind text NOT NULL DEFAULT 'posts' + CHECK (kind IN ('posts', 'gallery')); +CREATE TABLE page_hidden_files ( + page_id bigint NOT NULL REFERENCES pages(id) ON DELETE CASCADE, + file_id uuid NOT NULL REFERENCES files(id) ON DELETE CASCADE, + PRIMARY KEY (page_id, file_id) +); |
