migration
Change the Django database schema - one new numbered migration per change, never a rewrite of a merged migration. Use as soon as a model changes.
- License 许可
- MIT
- 最近更新
- 2026-11-15
- Stars
- ★ 3
- Forks
- 3
01 前言 Front Matter
- name
- migration
- description
- Change the Django database schema - one new numbered migration per change, never a rewrite of a merged migration. Use as soon as a model changes.
03 SKILL.md 正文
In a repo not yet updated to ion-repo, these variables are still named KILN_… (KILN_VPS for ION_REPO_VPS): use the one that is set.
Repo settings: !env | grep -E '^(KILN_(BACKEND_DIR|TEST_ENV)|PROJET_(BACK|ENV_TEST))=' | sort
(PROJET_BACK, PROJET_ENV_TEST in repos generated before kiln 0.4.)
Repo rules: those of its instructions (CLAUDE.md, .claude/rules/) take precedence over these.
Every model change comes with its numbered migration, applied at deployment without emptying the
database. Environment: set -a && . ../$ION_REPO_TEST_ENV && set +a from $ION_REPO_BACKEND_DIR/.
- Change the model.
- In
$ION_REPO_BACKEND_DIR/:uv run python manage.py makemigrations <app> --name <meaningful_name>(English, snake_case:riding_profile,station_photo). The file takes the app's next number. - Never edit or delete a migration already merged into the integration branch: production may have applied it. A mistake is fixed by a new migration. A migration still only on the branch can be regenerated.
- Seed data or data backfill: a data migration (
RunPython) with its reverse function, in a file separate from the schema change. - Column removed or renamed while the deployed code still reads it: two deliveries (the code stops reading it, then the migration removes it).
- Check:
uv run python manage.py makemigrations --check --dry-run(nothing to generate),uv run python manage.py migrateon the local database, thencharter checkfrom the root. - If an API schema changes too: skill
/django:regen-api.
04 同仓库更多 Skills
worktree
Create a work branch in a ready-to-use git worktree. The normal way to start a branch, so as not to cross another session in the main tree.
update
Update ion-repo - the ion-repo tool of the machine and its plugins, then the open repo (ion repo update, on a branch merged right away into develop). Use when the user asks to update ion-repo, or accepts the update offered at session start.
token
Set up a service's credentials (PyPI, Stripe, an API, a host…) in a `.<service>/` folder at the repo root (`token`, chmod 600, and `config` on its scope), with one command that pastes the token unseen. Use when a task needs an API key or a token, or when the user wants to give one.
statusline
Change the look of the status line - its style, its colors, among them the chat's (the person's and Claude's) - each shown before it is chosen. Use when the user wants another status line, other colors for it, or from `/repo:look`.
skill
Write or sharpen a skill of an Ion tool's plugin - intent, SKILL.md in the right craft's plugin, one trigger case, docs; tested with `claude plugin eval` only on request. Use when the user wants a new skill, to fix one, or to check one fires and does its job.
review
暂无简介