stop tracking generated migrations, and delete the stale one
Nothing applies these. There is no __drizzle_migrations table, `drizzle-kit migrate` has never run here, and `bun db:push` diffs the schema code against the live database directly — the schema code is the source of truth, as src/databases/CLAUDE.md says twice. The file was badly stale besides: 36 tables describing a schema from before capabilities, api_keys, agent_panels, the app store and the plugin system existed, including task_logs, terminal_containers and queue_jobs, which no longer exist anywhere in the codebase. Ignored rather than merely deleted, because `bun db:gen` reads src/schema.ts — whose last line imports plugin-schemas.gen.ts, generated from the plugin DIRECTORIES on whichever machine ran it. A committed migration would launder per-machine plugin state into the repository: generate it here and history gains music_* and offscale_*; generate it on a fresh clone and the next commit deletes them again. Two developers would fight over that file forever. Generating one locally to read a diff still works, and stays local. ── The history purge was tried and undone, deliberately ── git-filter-repo removed the blobs from all 1326 commits, cleanly: 1848 files became 1845, only the three migrations gone, every other blob byte-identical, verified against a bundle. It was reverted anyway. This codebase cites 76 commit SHAs as evidence — totality.ts points at2873948for the 2026-08-06 websocket incident, registry.ts at044aacf4, CLAUDE.md at f35c145 for the /chat exemplar — and a rewrite changes every one. They survived locally only through 1,328 replace refs, which are local to one clone and fooled my own verification into reporting the pre-rewrite commit as already clean. Three stale files nobody reads in old commits are not worth 76 dangling citations in a codebase whose documentation works by pointing at the commit that proves the claim. Untracking gets the entire practical benefit: gone from the tree, ignored forever, never regenerated into git. Recorded so nobody spends the afternoon rediscovering it.
This commit is contained in:
+23
@@ -70,3 +70,26 @@ build/
|
||||
build.next/
|
||||
src/apps/officer-web/Plugins.gen.tsx
|
||||
src/databases/officer_db/src/plugin-schemas.gen.ts
|
||||
|
||||
# drizzle-kit's generated migrations. Nothing applies them — there is no __drizzle_migrations table and
|
||||
# `drizzle-kit migrate` has never been run here; `bun db:push` diffs the schema code against the live
|
||||
# database and alters it directly. The schema code is the source of truth (src/databases/CLAUDE.md).
|
||||
#
|
||||
# Ignored rather than merely unused, because `bun db:gen` reads src/schema.ts — whose last line imports
|
||||
# plugin-schemas.gen.ts, itself generated from the plugin DIRECTORIES on this machine. So a generated
|
||||
# migration describes whichever plugins happen to be checked out here, and committing one would launder
|
||||
# per-machine state into the repository: run it with music installed and history gains music_*; run it on
|
||||
# a fresh clone and the next commit deletes them again.
|
||||
#
|
||||
# The old 0000_new_princess_powerful.sql is deleted from the WORKING TREE but left in history. It had 36
|
||||
# tables and described a schema from before capabilities, api_keys, the app store and the plugin system
|
||||
# existed, including three (task_logs, terminal_containers, queue_jobs) that no longer exist at all.
|
||||
#
|
||||
# Purging it from history was tried on 2026-08-15 and deliberately undone. This codebase cites 76 commit
|
||||
# SHAs in comments and docs as evidence — `totality.ts` points at 2873948 for the websocket incident,
|
||||
# `registry.ts` at 044aacf4, CLAUDE.md at f35c145 — and a filter-repo run rewrites every one of them.
|
||||
# Three stale files nobody reads in old commits are not worth 76 dangling citations in a codebase whose
|
||||
# documentation works by pointing at the commit that proves the claim.
|
||||
#
|
||||
# Generate one locally whenever a diff is useful to read. It stays local.
|
||||
src/databases/officer_db/migrations/
|
||||
|
||||
Reference in New Issue
Block a user