一键导入
add-migration
Create a numbered SQLite migration file and wire it into the MIGRATIONS array in db.rs. Follows the NNN_description.sql naming convention.
用 Codex 或 Claude 帮你安装 复制这段 Prompt,粘贴到 Codex、Claude 或其他助手里,让它检查 Skill 页面并帮你完成安装。
菜单
Create a numbered SQLite migration file and wire it into the MIGRATIONS array in db.rs. Follows the NNN_description.sql naming convention.
用 Codex 或 Claude 帮你安装 复制这段 Prompt,粘贴到 Codex、Claude 或其他助手里,让它检查 Skill 页面并帮你完成安装。
基于 SOC 职业分类
| name | add-migration |
| description | Create a numbered SQLite migration file and wire it into the MIGRATIONS array in db.rs. Follows the NNN_description.sql naming convention. |
| argument-hint | [description] |
Add a new SQLite migration to the services/ui database. Current migration count: 011.
Determine the next migration number
ls services/ui/migrations/ | sort | tail -5NNN + 1, zero-padded to 3 digitsCreate the migration file
services/ui/migrations/<NNN>_<description>.sql012_add_blog_posts.sql)CASCADE without PRAGMA foreign_keys, use INTEGER PRIMARY KEY for rowid alias-- Migration 012: add blog posts table
CREATE TABLE IF NOT EXISTS blog_posts (
id INTEGER PRIMARY KEY,
title TEXT NOT NULL,
body TEXT NOT NULL,
created TEXT NOT NULL DEFAULT (datetime('now'))
);
Wire into db.rs MIGRATIONS array
services/ui/src/db.rsMIGRATIONS static array (search for include_str!)include_str!("../migrations/<NNN>_<description>.sql"),
Verify
just dev — if the migration SQL is invalid, the app will panic at startup with a clear errorjust ui-run and confirm the DB opens without errorUpdate agent cache
.agent-cache/index.json → increment database.migration_count| Number | Description | Filename |
|---|---|---|
| 001 | initial schema | 001_initial_schema.sql |
| 008 | about section | 008_about_section.sql |
| 012 | add blog posts | 012_add_blog_posts.sql |
services/ui/migrations/ — all SQL filesservices/ui/src/db.rs — MIGRATIONS array and connection setupWrite a new Architecture Decision Record (ADR) using the project's numbering convention. Register it in INDEX.md and cross-reference affected module plans.
Add admin dashboard CRUD (list/detail/new/edit/delete) for a new entity following the Jobs and About patterns. Covers migration, DB helpers, React components, and API endpoints.
Create a drift log (DRL) documenting an incident, unexpected finding, or post-mortem. Register it in INDEX.md and cross-reference affected modules.
Create a new plan module file following CONVENTIONS.md template, register the domain code, and update INDEX.md. Keeps the plan system as the single source of truth.
Add a new Axum JSON API endpoint and/or React page route following the services/ui + web/ SPA patterns. Handles handler creation, router registration, and React component wiring.
Add a new AWS Secrets Manager secret following the W-SEC policy. Covers xtask registration, infra HCL, IAM policy, Lambda env wiring, and the put command.