Agent skill

Create Migration

by fullstackhero in fullstackhero/dotnet-starter-kit

Create and apply an EF Core migration for a module's DbContext the FSH way (central Migrations project, per-module folder, correct --context).

MITAuto-check passedDevelopment

Install Create Migration

skills CLI
$ npx skills add fullstackhero/dotnet-starter-kit --skill create-migration -a claude-code

Project install by default; add -g for ~/.claude/skills/.

GitHub CLI
$ gh skill install fullstackhero/dotnet-starter-kit create-migration --agent claude-code

Project scope by default; add --scope user for a personal install. Needs GitHub CLI 2.90.0 or later (public preview).

Manual copy
$ git clone --depth 1 https://github.com/fullstackhero/dotnet-starter-kit.git skills-src && mkdir -p .claude/skills && cp -r skills-src/.agents/skills/create-migration .claude/skills/create-migration && rm -rf skills-src

Use ~/.claude/skills/ instead of .claude/skills for a personal install. The folder must contain SKILL.md.

Claude Code skills documentation · loads skills from .claude/skills/

Facts

Skill name
create-migration
GitHub stars
6.8k
Token cost
~757 tokens
SKILL.md length
275 words
Files
1
Skills in repo
11
Repo updated
First seen
Licence
MIT

At a glance

Create and apply an EF Core migration for a module's DbContext the FSH way (central Migrations project, per-module folder, correct --context).

  • Works in 5 steps: restore the pinned tool (first time) → BUILD FIRST (snapshot footgun) → add the migration → …
  • Tasks that involve Project scaffolding
  • SKILL.md covers Step 0 — restore the pinned…, Step 1 — BUILD FIRST (snapshot…, Step 2 — add the migration and Step 3 — review the generated…, plus 3 more sections
  • Calls dotnet

What it does

Create Migration is an agent skill from fullstackhero/dotnet-starter-kit. Create and apply an EF Core migration for a module's DbContext the FSH way (central Migrations project, per-module folder, correct --context). Use after changing entities/EF config. See .agents/rules/database.md.

Its SKILL.md is about 760 tokens, which your agent loads only when the skill is triggered. It is a single SKILL.md file with no bundled scripts.

It sits in Development, covering Project scaffolding. It works with .NET. The repository describes itself as: Production Grade Cloud-Ready .NET 10 Starter Kit (Web API + React Client) with Multitenancy Support, and Clean/Modular Architecture that saves roughly 200+ Development Hours! All… The licence is MIT.

When your agent uses it

  • Tasks that involve Project scaffolding

Example prompts

  • “/create-migration”

Workflow steps

5 steps, taken from the step headings in SKILL.md.

  1. restore the pinned tool (first time)
  2. BUILD FIRST (snapshot footgun)
  3. add the migration
  4. review the generated SQL before applying
  5. apply

What it can do on your machine

Read from SKILL.md and the folder at commit 0bd98e3. It shows what the files ask for, not the result of running them.

  • Tool permissions

    Pre-approves nothing: there is no allowed-tools line, so your agent's usual permission prompts apply.

    From allowed-tools in the SKILL.md frontmatter.

  • Runs code

    Shell commands in SKILL.md call:

    • dotnet

    From the folder's file list and the shell code blocks in SKILL.md.

  • Network

    No URLs in SKILL.md.

    From URLs in SKILL.md, links to its own repository left out.

  • Credentials

    Names no API keys, tokens, secrets or passwords.

    From names ending in _API_KEY, _TOKEN, _SECRET, _KEY or _PASSWORD in SKILL.md.

Context cost

Create Migration loads about 757 tokens when it runs. Until then it costs about 57 tokens; SKILL.md has 275 words of instructions outside code blocks.

Always · name and description, kept in context so the agent knows when to use it
~57
When it runs · the whole SKILL.md, loaded when a task matches
~757

Estimates: characters ÷ 4, the usual rule of thumb; real counts depend on the model's tokenizer. Scripts and assets cost tokens only if the agent reads them.

Safety

Auto-check passed

The automated check found no risky patterns in SKILL.md.

Automated static check — not a guarantee. Review scripts before installing. It scans the text of SKILL.md for risky patterns (piping downloads into a shell, reading credential files, hidden Unicode, destructive commands); files beside SKILL.md are not scanned.

SKILL.md

The full file from fullstackhero/dotnet-starter-kit at commit 0bd98e3, republished under its MIT licence (© fullstackhero). 275 words, ~757 tokens.

Download SKILL.mdSave it as .claude/skills/create-migration/SKILL.md (or your agent's skills folder).
name
create-migration
description
Create and apply an EF Core migration for a module's DbContext the FSH way (central Migrations project, per-module folder, correct --context). Use after changing entities/EF config. See .agents/rules/database.md.
argument-hint
[ModuleName] [MigrationName]

Create Migration

All migrations live in one project — src/Host/FSH.Starter.Migrations.PostgreSQL — but are foldered per module/context (Catalog/, Identity/, …), each with its own {X}DbContextModelSnapshot. The DB is not migrated at API startup; the DbMigrator host applies it.

Step 0 — restore the pinned tool (first time)

bash
dotnet tool restore     # dotnet-ef is pinned in .config/dotnet-tools.json

Step 1 — BUILD FIRST (snapshot footgun)

dotnet ef migrations add reads the current snapshot, which is regenerated from a build. If you skip the build after editing entities/config, you can generate against a stale snapshot and lose changes. Also, migrations remove rewrites the snapshot — only remove the latest, and rebuild after.

bash
dotnet build src/FSH.Starter.slnx

Step 2 — add the migration

Specify all three of --project (the Migrations project), --startup-project (the API host), and --context {X}DbContext. Use --output-dir {X} so it lands in that module's folder (match the existing folder for the context).

bash
dotnet ef migrations add {MigrationName} \
  --project src/Host/FSH.Starter.Migrations.PostgreSQL \
  --startup-project src/Host/FSH.Starter.Api \
  --context {X}DbContext \
  --output-dir {X}

Step 3 — review the generated SQL before applying

bash
dotnet ef migrations script --idempotent \
  --project src/Host/FSH.Starter.Migrations.PostgreSQL \
  --startup-project src/Host/FSH.Starter.Api \
  --context {X}DbContext

Check for: unintended table/column drops, non-nullable columns added without a default to an existing table, and renames surfacing as drop+add (data loss). Adjust the model or hand-edit the migration if needed.

Step 4 — apply

Preferred (the canonical path — migrates the tenant catalog then each tenant's per-module schema):

bash
dotnet run --project src/Host/FSH.Starter.DbMigrator -- apply
dotnet run --project src/Host/FSH.Starter.DbMigrator -- list-pending   # to preview first

(Or, single-context local dev, dotnet ef database update --context {X}DbContext --project … --startup-project ….)

Notes

  • A new module also needs a {X}/ folder in the Migrations project and the runtime project referenced from it — see add-module.
  • dotnet ef against a BaseDbContext works because the 4-arg ctor is satisfied by the startup host's DI.

Checklist

  • dotnet tool restore done (first time)
  • Built before migrations add
  • --context {X}DbContext + --output-dir {X} (lands in the right folder)
  • Reviewed the generated SQL for data loss
  • Applied via DbMigrator apply (or ef database update for one context locally)

© fullstackhero, MIT. Rendered from Markdown: HTML in the file is shown as text, images as links, and headings moved down two levels. Raw file

Files

Just SKILL.md in .agents/skills/create-migration of fullstackhero/dotnet-starter-kit.

Open the folder on GitHubat commit 0bd98e3

Compare with similar skills

Create Migration next to the 5 skills that share the most tags, products or categories with it. Stars are the repository's; “used in” counts other GitHub owners with a copy.

Create Migration compared with similar skills
SkillStarsUsed inTokensAuto-checkLicenceRepo updated
Create Migration this skillfullstackhero/dotnet-starter-kit6.8k—~757Automated safety check: PassMIT
Scaffoldcodewithmukesh/dotnet-claude-kit751—~1.7kAutomated safety check: PassMIT
Revit Toolkit AnalyzersNice3point/RevitToolkit176—~3.8kAutomated safety check: PassMIT
Revit Toolkit InternalsNice3point/RevitToolkit176—~2.5kAutomated safety check: PassMIT
Corvus Benchmarkscorvus-dotnet/Corvus.JsonSchema199—~1.2kAutomated safety check: PassApache-2.0
Improve Skill Qualitydotnet/skills5.6k1 repos~3.6kAutomated safety check: PassMIT

Similar skills

  • Scaffold

    codewithmukesh/dotnet-claude-kit

    Architecture-aware feature scaffolding for .NET 10 projects.

    751 GitHub stars~1.7k tokensUpdated 2 mo ago
    DevelopmentAuto-check passed
  • Revit Toolkit Analyzers

    Nice3point/RevitToolkit

    Author and extend the Roslyn tooling bundled in the Nice3point.Revit.Toolkit package: the incremental source generator that emits external-event boilerplate, the analyzers and code fixers that…

    176 GitHub stars~3.8k tokensUpdated today
    DevelopmentAuto-check passed
  • Revit Toolkit Internals

    Nice3point/RevitToolkit

    Uphold the design contract of the Nice3point.Revit.Toolkit runtime library, that wraps the raw Revit add-in API.

    176 GitHub stars~2.5k tokensUpdated today
    DevelopmentAuto-check passed
  • Corvus Benchmarks

    corvus-dotnet/Corvus.JsonSchema

    Run, interpret, and maintain BenchmarkDotNet benchmarks for JSON Schema validation and query languages.

    199 GitHub stars~1.2k tokensUpdated today
    DevelopmentAuto-check passed
  • Official

    Diagnoses and fixes skills in the dotnet/skills repository that lose to their own baseline, fail to activate, time out, or return "no credible improvement".

    5.6k GitHub starsUsed in 1 repo~3.6k tokens
    DevelopmentAuto-check passed
  • Official

    Create a new ASP.NET Core web application or web site using Blazor.

    5.6k GitHub starsUsed in 1 repo~3k tokens
    DevelopmentAuto-check passed

More from fullstackhero/dotnet-starter-kit

All 11 skills in this repo
  • Add Entity

    fullstackhero/dotnet-starter-kit

    Add a domain entity/aggregate with EF configuration and a migration to an existing FSH module.

    6.8k GitHub stars~1.2k tokensUpdated 7 days ago
    Auto-check passed
  • Add Feature

    fullstackhero/dotnet-starter-kit

    Add a vertical-slice feature (command/query + handler + validator + endpoint) to an existing FSH module.

    6.8k GitHub stars~1.1k tokensUpdated 7 days ago
    Auto-check passed
  • Add Full Slice

    fullstackhero/dotnet-starter-kit

    Build a capability end-to-end — backend vertical slice (Contracts→handler→validator→endpoint) AND the React page wired to it.

    6.8k GitHub stars~783 tokensUpdated 7 days ago
    Auto-check passed
  • Add Integration Event

    fullstackhero/dotnet-starter-kit

    Publish a cross-module integration event via the Outbox and handle it idempotently in another module.

    6.8k GitHub stars~1.1k tokensUpdated 7 days ago
    Auto-check passed
  • Add Module

    fullstackhero/dotnet-starter-kit

    Create a new module (bounded context) — runtime + Contracts projects, IModule, DbContext, permissions, migrations, and the four registration sites.

    6.8k GitHub stars~1.5k tokensUpdated 7 days ago
    Auto-check passed
  • Add Permission

    fullstackhero/dotnet-starter-kit

    Add a new permission end-to-end — server constant + endpoint gate, and (admin app) mirror it into the permissions catalog + route guard.

    6.8k GitHub stars~849 tokensUpdated 7 days ago
    Auto-check passed

Works with

Questions about Create Migration

What does Create Migration do?

Create and apply an EF Core migration for a module's DbContext the FSH way (central Migrations project, per-module folder, correct --context). Create Migration is an agent skill from fullstackhero/dotnet-starter-kit. Create and apply an EF Core migration for a module's DbContext the FSH way (central Migrations project, per-module folder, correct --context).

When should I use Create Migration?

Create Migration fits situations like: tasks that involve Project scaffolding.

How do I install Create Migration in Claude Code?

Run `npx skills add fullstackhero/dotnet-starter-kit --skill create-migration -a claude-code`. Or copy the skill folder (.agents/skills/create-migration in fullstackhero/dotnet-starter-kit) into .claude/skills/create-migration in your project. Claude Code loads it when a task matches its description.

How do I install Create Migration in Codex?

Run `npx skills add fullstackhero/dotnet-starter-kit --skill create-migration -a codex`. Or copy the skill folder (.agents/skills/create-migration in fullstackhero/dotnet-starter-kit) into .agents/skills/create-migration in your project. Codex loads it when a task matches its description.

Can I use Create Migration in Cursor, Gemini CLI or GitHub Copilot?

Cursor, Gemini CLI, GitHub Copilot and OpenCode also load SKILL.md folders. With the skills CLI, run `npx skills add fullstackhero/dotnet-starter-kit --skill create-migration -a cursor` (or -a gemini-cli, github-copilot or opencode for the others). To copy it by hand, put the folder in .cursor/skills/create-migration, .gemini/skills/create-migration, .github/skills/create-migration and .opencode/skills/create-migration in your project.

What does Create Migration need to run?

Going by SKILL.md and its folder, Create Migration needs the command-line tools its instructions call (dotnet).

Does Create Migration access the network?

SKILL.md contains no URLs. Any network use would come from the scripts or tools the agent runs. This is read from the text; nothing was executed.

Is Create Migration safe to install?

Our automated static check of SKILL.md found no risky patterns, such as piping downloads into a shell, reading credential files or hidden Unicode. It is not a guarantee. Review the folder before installing.

What licence does Create Migration use?

Create Migration is published under the MIT licence (the repository's licence). It allows redistribution, so the full SKILL.md is shown on this page.

How many tokens does Create Migration use?

About 757 tokens (SKILL.md is roughly 3k characters). Agents keep only the skill's name and description in context until a task matches; then they load SKILL.md in full.

What are the alternatives to Create Migration?

Skills that share tags, products or a category with Create Migration: Scaffold (codewithmukesh/dotnet-claude-kit, 751 stars), Revit Toolkit Analyzers (Nice3point/RevitToolkit, 176 stars), Revit Toolkit Internals (Nice3point/RevitToolkit, 176 stars) and Corvus Benchmarks (corvus-dotnet/Corvus.JsonSchema, 199 stars). The comparison table on this page puts their stars, adoption, token cost, safety result and licence side by side.

Who maintains Create Migration?

fullstackhero (a GitHub organization) maintains it in fullstackhero/dotnet-starter-kit, which has 6,813 GitHub stars. The repository holds 11 skills in this directory. The repository was last updated on September 30, 2026.

Source: fullstackhero/dotnet-starter-kit on GitHub. Facts on this page come from the repository at the commit we read; the author's words are quoted as theirs.