Skip to main content
net8.0net9.0net10.0

Addin for running liquibase database migrations with the Cake build system.

Published
Nov 13, 2025
11mo ago
Total Downloads
26.8K
26,817

Install

dotnet add package Cake.Liquibase --version 0.1.18
ProductVersions
.NET
net10.0net8.0net9.0

README

Cake.Liquibase

Addin for running liquibase database migrations with the Cake build system.

NuGet

Dependencies

Please note that neither the required Java Runtime Environment (JRE) nor the liquibase executables are provided with this addin and need to be provided separately.

NuGet package

As of now there is only a preview NuGet package available. An official one will be created as soon as I'm satisfied with the code to release a first version.

Usage

#addin "Cake.Liquibase"

var target = Argument("target", "Default");

Task("Default")
    .Does(() => {
        // Install Liquibase.Cli package for the liquibase executables (or include it in the packages.config) 
        NuGetInstall("Liquibase.Cli", new NuGetInstallSettings {
            Version  = "3.3.5",
            OutputDirectory = "./tools"
        });

        UpdateDatabase(s => {
            s.ChangeLogFile = "YourChangeLog.xml";
            s.Url = "jdbc:sqlite:exampledb.sqlite";
            s.JavaSettings.Classpaths.Add("./sqlite-jdbc-3.20.0.jar"); // additional drivers / jar files
        });
    });

RunTarget(target);

When not specifying a java executable the PATH is searched for "java" and it is used when found.

Limitations

This is currently an early stage of the addin. As of now only the liquibase "update" command is supported. The most important settings can be used via the LiquibaseSettings class. If you are missing settings, you can use the LiquibaseSettings.ArgumentCustomization property to define them as string. Details on how to use them can be found on the Cake website (ToolSettings).

If you are missing a command or parameter feel free to send a pull request.

Changes from Previous Version

v0.1.17v0.1.18
Added Frameworks
net10.0

Adoption Assessment

Assess this package against its supported frameworks, license, maintenance signals and dependency graph before making it a project standard.

Compatibility metadata lists 3 target frameworks; confirm the exact target used by your application.

Related Guides & Workflows

Learn how to evaluate, integrate, or audit this package in your .NET project.