Diff and Update
This page lists the commands and flags. See Diffing & Updates for the behavior behind them.
tuff diff
Section titled “tuff diff”Show unified diff between baseline and installed files, or compare against latest upstream:
# Local changes against baselinetuff diff <id>
# Upstream changes since last install (git-sourced only)tuff diff <id> --upstream
# Diff a specific agenttuff diff <id> -a claude
# Machine-readable: one object per agent listing changed filestuff diff <id> --json
# Preview what a different release requirement would changetuff diff <id>@^2 --upstream--json is the same as --format json; pass one or the other.
Capabilities installed at a release
Section titled “Capabilities installed at a release”For a capability installed at a release, --upstream compares against the newest release your recorded requirement allows, which is the same content tuff update would install, never the latest commit.
- An exact pin therefore reports
no upstream changes in v1.2.0, since nothing newer is allowed. tuff diff <id>@<requirement> --upstreampreviews a different requirement. For example,@^2shows what lifting the pin to the next major would change beforetuff update <id>@^2does it.- A note on standard error names the release compared against, and the JSON carries it as
upstream, so the patch on standard output stays a patch.
A capability pinned to a commit rather than a release still compares against the latest commit.
When standard output is a terminal, diff headers are cyan, additions are green, and deletions are red, matching the usual Git diff convention. Piped or captured output is plain automatically; set NO_COLOR=1 to disable color explicitly.
tuff update
Section titled “tuff update”Update a capability according to its recorded source:
| Source | What update does |
|---|---|
| In-place local capability | Accepts current edits as the new baseline |
| External local source | Reloads from sourcePath |
| Git source | Three-way merge between baseline, local, and upstream |
See the lifecycle docs for the merge behavior table.
# Update the configured default agenttuff update <id>
# Dry run: show what would happen without applyingtuff update <id> --check
# Update a specific agent insteadtuff update <id> -a <agent>
# Force overwrite local changes with recorded source outputtuff update <id> --force
# Explicit scopetuff update <id> --scope global
# Change the release requirement of a tag-pinned capability, then movetuff update <id>@^2Capabilities installed at a release
Section titled “Capabilities installed at a release”A capability installed at a release never moves to the latest commit.
tuff update <id>moves to the newest release the recorded requirement allows, and says so when that release is already installed.tuff update <id>@<requirement>records a new requirement and moves to the newest release it allows. This is how an exact pin such as1.2.0is lifted.- With
--check, the preview names the release and the claimed size of the change, as into 1.4.0 (minor), before anything is written.
If the installed tag now names a different commit than when you installed it, update refuses rather than calling it up to date. --check says what the tag names now, tuff diff <id> --upstream shows the difference, and --force replaces the install with it.
Capabilities installed from a pack update with the pack; see Update a pack.