update
dbt-forge update re-renders the dbt-forge templates using the stored project
configuration and shows unified diffs for any files that have changed. Use it after
upgrading dbt-forge to pick up template improvements.
Command
Section titled “Command”dbt-forge update [--dry-run]What it does
Section titled “What it does”The command:
- Reads the
.dbt-forge.ymlmanifest written duringinit - Reconstructs the original
ProjectConfigfrom the manifest - Re-renders all templates with the current version of dbt-forge
- Compares each rendered file against the on-disk version
- Reports counts of unchanged, changed, and new files
In interactive mode (default), each changed file is shown as a unified diff and you
can accept or skip the update. In --dry-run mode, only the diff summary is printed.
Options
Section titled “Options”--dry-run
Section titled “--dry-run”Preview changes without writing anything. Shows the list of changed and new files with their diffs.
dbt-forge update --dry-runManifest
Section titled “Manifest”The .dbt-forge.yml file is created automatically when you run dbt-forge init.
It stores:
dbt_forge_version— the version of dbt-forge that generated the projectcreated_at— ISO timestamp of generationconfig— serializedProjectConfig(adapter, marts, packages, feature flags)files— map of relative file paths to SHA-256 content hashes
The manifest is required for update to work. Projects created before this feature
was added will need to be re-generated with init to get a manifest.
Output
Section titled “Output” dbt-forge update — my_dbt_project
22 unchanged 2 changed 0 new
Changed files: M README.md M .github/workflows/dbt_ci.ymlIn interactive mode, each changed file shows a syntax-highlighted unified diff followed by a prompt:
--- README.md ---@@ -1,4 +1,5 @@ # my_dbt_project+ ## Setup-Run dbt debug to verify.+Run `uv run --env-file .env dbt debug` to verify.
? Apply changes to README.md?> accept skipSelect accept to overwrite the file with the new version, or skip to leave it unchanged. After all files are reviewed, the manifest is updated to reflect the current state.
Behavior and limits
Section titled “Behavior and limits”- Must run from inside an existing dbt project with a
.dbt-forge.ymlmanifest. - Only files tracked in the manifest are compared. Files added after
init(viaaddcommands or manually) are not affected. - Accepted changes overwrite the on-disk file. Skipped changes leave the file unchanged.
- The manifest is updated after changes are applied.
- Does not require a warehouse connection.