원클릭으로
alembic-migration-manager
Use when creating or managing database migrations with Alembic
Codex 또는 Claude로 설치 이 Prompt를 복사해 Codex, Claude 또는 다른 어시스턴트에 붙여 넣으면 Skill 페이지를 검토하고 설치를 진행할 수 있습니다.
메뉴
Use when creating or managing database migrations with Alembic
Codex 또는 Claude로 설치 이 Prompt를 복사해 Codex, Claude 또는 다른 어시스턴트에 붙여 넣으면 Skill 페이지를 검토하고 설치를 진행할 수 있습니다.
SOC 직업 분류 기준
Record browser-based feature demos as GIFs via Playwright and optionally document them in docs/features/index.md. Trigger with "Demo <feature>" or "Demo and Document <feature>".
Use when creating service modules in apps/api/skillhub/services/
Use when writing API tests in apps/api/tests/
Use when implementing division-based access control on any endpoint
Use when adding services to docker-compose.yml or creating Dockerfiles
Use when implementing error handling across the API, frontend, or MCP server
| name | alembic-migration-manager |
| description | Use when creating or managing database migrations with Alembic |
| Task | Command |
|---|---|
| Generate from models | mise run db:make-migration "description" |
| Apply all | mise run db:migrate |
| Rollback one | mise run db:rollback |
| Rollback all | mise run db:rollback:all |
| Check status | mise run db:check |
| Full reset | mise run db:reset |
libs/db/alembic/versions/YYYYMMDD_HHMM_description.py
# 1. Edit model in libs/db/skillhub_db/models/
# 2. Generate migration
mise run db:make-migration "add user_preferences table"
# 3. Review generated file
# 4. Apply
mise run db:migrate
def upgrade():
op.add_column('skills', sa.Column('deprecated_at', sa.DateTime))
op.create_index('idx_skills_deprecated', 'skills', ['deprecated_at'])
def downgrade():
op.drop_index('idx_skills_deprecated')
op.drop_column('skills', 'deprecated_at')
def upgrade():
# Schema change
op.add_column('skills', sa.Column('new_field', sa.String))
# Data backfill
op.execute("UPDATE skills SET new_field = old_field WHERE old_field IS NOT NULL")
alembic check in CI fails if models diverge from migrations. Run mise run db:check locally before committing.
libs/db/alembic.inilibs/db/alembic/versions/001_initial_schema.pylibs/db/skillhub_db/models/