github grate-devs/grate 2.3.0

3 hours ago

grate 2.3.0 adds database-specific distributions alongside the all-in-one package, CI-aware migration logging with activity groups and progress, interactive terminal progress, SQL Server restore file relocation, and SQL Server script diagnostics, alongside migration correctness fixes and improvements to documentation and release tooling.

New features

  • Improve migration logging with native CI groups, progress and warning/error annotations, plus live progress in capable interactive terminals. The format is detected automatically or selected with --log-format. #904, #934, closes #903.
  • Add database-specific packages for SQLite, SQL Server, MariaDB, PostgreSQL and Oracle alongside the all-in-one package, across CLI archives, .NET tools, Docker and native package formats. Each variant defaults to its selected database. #910.
  • Relocate SQL Server backup files during restore with repeatable --restore-move 'logical-name=destination-path' options. Library consumers can use RestoreFileMove, GrateConfiguration.RestoreMoves and WithRestoreMoves(...). Validate mappings before migration, quote restore inputs correctly, and attempt to restore MULTI_USER access after a restore failure while retaining the original exception. Existing restore calls remain supported. #908, closes #593.
  • Include SQL Server PRINT and other informational script messages at Debug/Trace verbosity, with the script name. Default Information output is unchanged; SQL errors still fail migrations. #907, closes #594.

Database-specific distributions

Choose a package containing the provider you need, or keep the existing all-in-one package. Every variant exposes the same grate command. A database-specific build defaults to its selected database and rejects unsupported provider selections before migration starts. The all-in-one package keeps SQL Server as its default. #910, related to #909.

Distribution .NET tool ID / release file prefix Default database
All grate SQL Server
SQLite grate-sqlite SQLite
SQL Server grate-sqlserver SQL Server
MariaDB grate-mariadb MariaDB
PostgreSQL grate-postgresql PostgreSQL
Oracle grate-oracle Oracle
  • Each distribution has self-contained ZIPs for the existing nine platform/architecture combinations, Windows x64/Arm64 MSI installers, and Debian amd64/arm64 packages. Packaging now produces 54 ZIPs, 12 MSIs and 12 Debian packages, plus checksums and a release manifest.
  • Six framework-dependent .NET tools retain net8.0/net9.0/net10.0/net11.0 assets. The six existing dotted-name library packages, such as grate.sqlite and grate.sqlserver, remain separate from the hyphenated CLI tools.
  • Docker adds gratedevs/grate:sqlite-2.3.0, :sqlserver-2.3.0, :mariadb-2.3.0, :postgresql-2.3.0 and :oracle-2.3.0, each for linux/amd64 and linux/arm64. Stable profile aliases use :sqlite, :sqlserver, :mariadb, :postgresql and :oracle. Existing all-in-one version/latest tags and the digest-identical erikbra/grate compatibility copy retain their behavior; no profile tags are added to the compatibility repository.
  • Stable release tooling updates six casks in the existing erikbra/cask tap and prepares six WinGet identity candidates, six Chocolatey x64 packages and six Homebrew source-formula candidates. WinGet/Chocolatey submission and acceptance, and source-formula channel placement, remain separate. New identities become installable only after their release/publication or acceptance steps complete.

See the distribution guide and complete distribution catalog for filenames, channels and platform coverage.

Fixes

  • Report transaction commit failures as migration failures rather than success. Log the underlying cause and attempt to record version status Error after disposing the transaction. Includes a real PostgreSQL deferred-constraint regression. #899, closes #647.
  • Use default database creation when a configured custom creation folder contains no SQL files, preserving creation-dependent follow-up scripts and dry-run behavior. #897, closes #532.
  • Reject missing explicitly configured CLI migration directories before starting migration. Report the folder key/path and exit with code 1, including for configuration-file mappings. Standard folders without explicit path overrides remain optional. #898, closes #292.
  • Create bootstrap temporary directories directly, avoiding temporary-file conversion and deletion of an existing directory. This addresses a failure observed while preparing bootstrap scripts on Windows. #934.

Dependencies and contributor tooling

  • Move source builds to stable .NET SDK 11.0.100. Self-contained CLI archives, MSI/Debian installers and all six Alpine 3.24 Docker profiles bundle stable .NET runtime 11.0.0. Framework-dependent tools and libraries retain net8.0/net9.0/net10.0/net11.0 assets and use the matching installed runtime. #943.

  • Update System.Security.Cryptography.Pkcs to 10.0.14 across all four target frameworks. Refresh standalone .NET 10 examples and their dependencies, and retry transient pinned WiX downloads without weakening checksum checks. #926.

  • Replace grate.sln with grate.slnx, preserve solution/filter membership and build mappings, consolidate NuGet configuration, audit direct/transitive dependencies at all severities, and enable package pruning. #928.

  • Convert repository automation to PowerShell and retain the small runtime shell launchers. #917.

  • Validate complete PR CI evidence, stage expensive checks behind build/isolated tests, and run shared build-independent checks before compilation. Main protection remains a separate proposal. #913, #922, #927.

  • Normalize C# whitespace/encoding and add a shared changed-file formatting check; configure advisory CodeRabbit reviews; update CodeQL Action to 4.39.3. #923, #912, #902, #936.

  • Retry macOS Arm64 SDK installation once in fresh installation and temporary directories, validate the selected SDK and Arm64 host, and fail if recovery does not succeed. This prevents a partial installation from being accepted by the retry. #933.

  • Refresh CodeQL on main pushes and a weekly schedule. Add read-only PR dependency review and a resolved direct/transitive NuGet audit, rejecting high/critical findings and audit-feed failures. These workflow changes do not activate repository rulesets or required-check settings. #911.

  • Bound Windows MSI lifecycle verification waits and retain process/progress evidence on failure. Organize GitHub Actions display names by purpose, update docker/login-action to 4.8.0, and update the xUnit MTP package to 4.0.3. #934, #935, #937.

  • Split CI and release orchestration into reusable phase workflows. Expand matching CLI/tool, native installer and database-version checks across the all-in-one and database-specific builds, and maintain a generated distribution catalog checked during preflight. #910.

Documentation and examples

  • Clarify migration folder defaults/order, script policies, database setup and safe migration workflows in the bundled use-grate skill. #896, #895.
  • Clarify that --output stores migration artifacts; capture console logs by redirecting stdout/stderr. #906.
  • Document provider connection strings and add a runnable PostgreSQL Compose example. Refresh the README, SQLite quick start and contributor guidance. #905, #929.
  • Document Chocolatey packaging/moderation, WinGet community submission, and the expanded distribution catalog. Release tooling retains package candidates; public-feed submission and acceptance remain separate. #900, #901, #910.

Upgrade notes

  • All CLI variants install command grate. Uninstall the installed variant before switching tools or package-manager variants. MSI upgrade families and package conflict checks distinguish profiles; same-profile upgrades remain supported. Existing all-in-one package names and MSI identity derivation are preserved. A database-specific package supports only its selected provider; use the all-in-one package for multiple providers. #910.
  • Interactive terminal output now defaults to activity headings and live progress when supported. Pass --log-format=console to retain the previous terminal presentation. Warnings/errors keep their stderr routing, and --isuptodate retains its exact result line without progress output.
  • CI environments now default to the detected log format and write CI logs to stdout. If a pipeline parses the previous terminal format or relies on the stdout/stderr split, pass --log-format=console to retain that behavior. Docker callers must forward relevant runner environment variables or select the format explicitly.
  • Explicit --folders path overrides must exist, even when they name the usual default path. A fully custom folder list requires every selected directory. Type-only overrides of standard folders keep inherited paths optional. Library consumers retain their existing folder-validation behavior.
  • Restore mappings are SQL Server-only and require --restore; their destination paths are on the SQL Server host. Without mappings, the existing restore mode remains available.
  • Contributor scripts referring to grate.sln must use grate.slnx; use PowerShell 7 for repository automation. This does not require a new runtime for consumers of existing net8/net9/net10 library/tool assets.
  • Stable publication covers all six CLI distributions on GitHub, six .NET tools plus six libraries, six canonical Docker profiles and six Homebrew casks. The erikbra/grate Docker compatibility copy continues for the all-in-one image. WinGet/Chocolatey candidates and Homebrew source-formula candidates require their separate submission or placement steps. See the release process.

Full changelog: 2.2.0...2.3.0.

Don't miss a new grate release

NewReleases is sending notifications on new releases.