Generates Entity Framework Core (EF Core) database migrations for C# / .NET projects based on the entity model specification in docs/entity_model.md. Use when the user asks to "create database migration", "add ef migration", "update schema with ef core", "generate db migration for .net", or mentions EF Core, DbContext, or database migrations in C#.
68
81%
Does it follow best practices?
Run evals on this skill
Adds up to 20 points to the overall score
View guide
Passed
No findings from the security scan
Create a native EF Core C# Migration (dotnet ef migrations add <MigrationName>) and configure entity models in DbContext based on docs/entity_model.md.
Read docs/entity_model.md to inspect the required entities, attributes, relationships, and validation constraints.
Inspect existing DbContext and Entity Classes under the project solution (.csproj).
Generate/Update Entity Classes & Configurations:
public required string Name { get; set; }).public List<OrderItem> Items { get; set; } = []; or public Customer Customer { get; set; } = null!;).IEntityTypeConfiguration<T> for Fluent API mappings (table names, column types, HasPrecision(18, 2) for decimal fields, HasConversion<string>() for enums, foreign keys, and unique indexes).OnModelCreating(ModelBuilder modelBuilder) (or use modelBuilder.ApplyConfigurationsFromAssembly(...)).Generate EF Core Migration:
dotnet ef migrations add UCXXX_Description using CLI. For multi-project solutions, specify project flags (e.g. dotnet ef migrations add UCXXX_Description --project src/MyApp.Data --startup-project src/MyApp.Web).Migrations/.DO NOT:
appsettings.json or environment variables.Next Step Guidance:
"Next step: Run
/implement UC-XXX(e.g./implement UC-001) to construct your vertical slice feature."
c3a5da3
If you maintain this skill, you can claim it as your own. Once claimed, you can manage eval scenarios, bundle related skills, attach documentation or rules, and ensure cross-agent compatibility.