agentleFS
TienDat-VnaTienDat-Vna/BackSpec/.agents/skills/db-migration/SKILL.md

db-migration

Skill1 starsChanged 45 days agoMITView on GitHub

Tạo file migration cơ sở dữ liệu mới (Flyway / Liquibase / Alembic / Prisma / golang-migrate) đảm bảo tính bất biến, audit columns, soft delete và không downtime.

24 other projects use a version of this.

Adopted by

Most recently taken up by

Used with

Projects with it also use api-endpoint, write-tests and 6 more.

Other files people use alongside this one.

Files found in the same public projects as a version of this one, more often than they turn up anywhere else. Each project counts once, large collections count for less, and this file's own repository is left out.
  • tadoEngSkill

    api-endpoint

    Add or change a backend API endpoint on this product, keeping Pydantic as the single contract authority and regenerating the TypeScript client. Use when asked to add an endpoint, expose data to the frontend, change a request or response shape, or wire a new backend capability into a page.

    Also in 4 projects that use this

  • SentrySkill

    write-tests

    Write tests following project conventions. Use when adding new tests or modifying existing ones.

    Also in 3 projects that use this

  • Microsoft AzureSkill

    design

    Design rules and conventions for the API Center Portal. Use when editing detail pages, card components, badges, layout, navigation, sidebars, or headers. Covers badge styling, metadata placement, page navigation patterns, and layout alignment.

    Also in 3 projects that use this

  • Microsoft AzureSkill

    verify

    End-to-end app testing pipeline for browser-based web apps on cloud browsers via Azure Playwright Workspaces: verify the live app, author tests for working flows, heal failing tests, then re-run with video and produce one consolidated report. Three phases (app verification, test authoring, test healing) plus a scoped final sanity run; each phase emits a sub-report. Use when asked to "verify my app", "make sure my app works and has good test coverage", "do a full QA pass", "add tests where I'm missing coverage", "fix failing tests and add new ones", "smoke test before deploy", "QA my deployment", or any combined verify-and-test ask. Requires Azure CLI (`az login`) and a Playwright Workspace resource ID — bootstraps configs on first invocation. Browser-based web apps with Playwright only — not for unit/API tests, native mobile/desktop, load/perf, or full accessibility audits.

    Also in 4 projects that use this

  • AnthropicSkill

    debug

    Structured debugging session — reproduce, isolate, diagnose, and fix. Trigger with an error message or stack trace, "this works in staging but not prod", "something broke after the deploy", or when behavior diverges from expected and the cause isn't obvious.

    Also in 3 projects that use this

  • VercelSkill

    agent-browser

    Automates browser interactions for web testing, form filling, screenshots, and data extraction. Use when the user needs to navigate websites, interact with web pages, fill forms, take screenshots, test web applications, or extract information from web pages.

    Also in 3 projects that use this

The file

Files
SKILL.md
<!-- GENERATED FROM registry/skills/db-migration/SKILL.md — DO NOT EDIT DIRECTLY --><!-- GENERATED FROM .shared/skills/02-codestyle/db-migration/SKILL.md — DO NOT EDIT DIRECTLY -->

Skill — Database Migration (Backend Microservice)

Hướng dẫn Agent tạo file migration cơ sở dữ liệu an toàn.

Checklist trước khi tạo migration:

  1. Kiểm tra migration cũ: Không bao giờ sửa đổi file migration cũ đã tồn tại.
  2. Xác định phiên bản tiếp theo: Đọc thư mục migration để lấy version tăng dần (vd V2__add_status_column.sql).
  3. Quy chuẩn bắt buộc trong script:
    • Bảng mới phải có cột audit: created_at, updated_at, created_by.
    • Bảng mới phải có cột soft delete: is_deleted hoặc status.
    • Cột thêm vào bảng cũ phải là NULLABLE hoặc có DEFAULT.
    • Tạo Index có điều kiện cho các trường truy vấn thường xuyên.
  4. Cập nhật Entity & DTO: Sau khi viết file migration, cập nhật Entity class và DTO mapping tương ứng.

Download now (ZIP)

Does it work?

Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.

No reviews yet

People and AI agents can review whether this works in practice. Say what you used it for, and whether it worked.

  • It worked
  • Partly
  • It didn't
What did you use it for? e.g. Reviewing pull requests in a Rails app

Using an agent? It can post a review for you after it has run the file: the MCP tool registry_write, action report. How to connect one.

Your trail

Files you open will collect here, so you can find them again.

Open two or more, and you can remix the rules you like from each into one list. Kept in this browser only.

Now do this for your own.

Bring your CLAUDE.md, AGENTS.md or skills. agentleFS shows which of your rules are common, which are yours and which only fit one project, and keeps one version your agents read everywhere.