chore: effect pattern lint infrastructure (#35210)

This commit is contained in:
Kit Langton 2026-07-03 13:58:26 -04:00 committed by GitHub
commit 1401901529
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
70 changed files with 524 additions and 234 deletions

View file

@ -1,11 +1,11 @@
import { sqliteTable, text, integer, primaryKey } from "drizzle-orm/sqlite-core"
import * as DatabasePath from "../database/path"
import { absoluteArrayColumn, absoluteColumn } from "../database/path"
import { Timestamps } from "../database/schema.sql"
import { ProjectSchema } from "./schema"
export const ProjectTable = sqliteTable("project", {
id: text().$type<ProjectSchema.ID>().primaryKey(),
worktree: DatabasePath.absoluteColumn().notNull(),
worktree: absoluteColumn().notNull(),
vcs: text(),
name: text(),
icon_url: text(),
@ -13,7 +13,7 @@ export const ProjectTable = sqliteTable("project", {
icon_color: text(),
...Timestamps,
time_initialized: integer(),
sandboxes: DatabasePath.absoluteArrayColumn().notNull(),
sandboxes: absoluteArrayColumn().notNull(),
commands: text({ mode: "json" }).$type<{ start?: string }>(),
})
@ -24,7 +24,7 @@ export const ProjectDirectoryTable = sqliteTable(
.$type<ProjectSchema.ID>()
.notNull()
.references(() => ProjectTable.id, { onDelete: "cascade" }),
directory: DatabasePath.absoluteColumn().notNull(),
directory: absoluteColumn().notNull(),
type: text().$type<"main" | "root" | "git_worktree">(),
strategy: text(),
time_created: integer()