EFContinuousMigrations 6.0.4

dotnet add package EFContinuousMigrations --version 6.0.4                
NuGet\Install-Package EFContinuousMigrations -Version 6.0.4                
This command is intended to be used within the Package Manager Console in Visual Studio, as it uses the NuGet module's version of Install-Package.
<PackageReference Include="EFContinuousMigrations" Version="6.0.4" />                
For projects that support PackageReference, copy this XML node into the project file to reference the package.
paket add EFContinuousMigrations --version 6.0.4                
#r "nuget: EFContinuousMigrations, 6.0.4"                
#r directive can be used in F# Interactive and Polyglot Notebooks. Copy this into the interactive tool or source code of the script to reference the package.
// Install EFContinuousMigrations as a Cake Addin
#addin nuget:?package=EFContinuousMigrations&version=6.0.4

// Install EFContinuousMigrations as a Cake Tool
#tool nuget:?package=EFContinuousMigrations&version=6.0.4                

Entity Framework Continuous Migrations

What is EF Continuous Migrations?

Entity Framework Continuous Migrations is an EF Core extension for conditionally applying pending migrations to a database at runtime using application configuration settings.

Why would I use it?

You want to ensure the latest EF migrations have been applied during application startup. An example of this would be during an ASP.NET Core application at startup for a given development environment.

How do I use it?

EF Continuous Migrations is added to an application using the AddContinuousMigrations<T> IServicesCollection extension method.

The following example shows how this is done for an ASP.NET Core application in the Startup.ConfigureServices method for an application using a MySql database.

services
    .AddDbContext<ApplicationDbContext>(options =>
        options
            .UseMySql(Configuration.GetConnectionString("DefaultConnection"))
    )
    .AddContinuousMigrations<ApplicationDbContext>()
    .AddControllersWithViews();

EF Continuous Migrations is enabled by default and requires no configuration settings. In order to disable migrations from being applied add the following configuration to a your appsettings.{environment}.json file:

  "ContinuousMigrations": {
    "Enabled": false
  }

A working example can be seen in the Sample application.

Issue?

If you have any issues please report it here.

Product Compatible and additional computed target framework versions.
.NET net6.0 is compatible.  net6.0-android was computed.  net6.0-ios was computed.  net6.0-maccatalyst was computed.  net6.0-macos was computed.  net6.0-tvos was computed.  net6.0-windows was computed.  net7.0 was computed.  net7.0-android was computed.  net7.0-ios was computed.  net7.0-maccatalyst was computed.  net7.0-macos was computed.  net7.0-tvos was computed.  net7.0-windows was computed.  net8.0 was computed.  net8.0-android was computed.  net8.0-browser was computed.  net8.0-ios was computed.  net8.0-maccatalyst was computed.  net8.0-macos was computed.  net8.0-tvos was computed.  net8.0-windows was computed. 
Compatible target framework(s)
Included target framework(s) (in package)
Learn more about Target Frameworks and .NET Standard.

NuGet packages

This package is not used by any NuGet packages.

GitHub repositories

This package is not used by any popular GitHub repositories.

Version Downloads Last updated
6.0.4 517 4/24/2022
5.0.9 420 9/5/2021
5.0.8 343 9/5/2021
5.0.7 374 9/5/2021
3.1.18 359 9/5/2021
3.1.17 356 9/5/2021
1.0.0 630 4/12/2020