Skip to content

Terminal snapshots

A terminal target runs a command and snapshots its output — exit code, signal, and the stdout/stderr streams — with ANSI styling normalized into structured segments.

Configure a target

json
{
  "kind": "terminal",
  "name": "cli-help",
  "command": "my-app --help"
}

Options:

  • command — the command to run.
  • cwd — working directory, resolved relative to the config (default: the config directory).
  • timeoutMs — per-target timeout; falls back to lifecycle.wait.timeoutMs.

ANSI normalization

The normalization.ansi setting controls how styling is captured:

  • "semantic" (default) keeps styling as structured segments, so a color or bold change is a reviewable diff rather than a stream of raw escape codes.
  • "strip" keeps text only.

Either way, mask rules are applied so dynamic content (timestamps, ids) doesn't cause false diffs.

How it's compared

Terminal streams use a word-level inline text diff — insertions render as {+added+} and deletions as [-removed-]. Exit code and signal changes are reported on their own lines, and a styling-only change (same text, different segments) is called out explicitly:

diff
  ~ stdout:
- build passed in 10s
+ build passed in {+12s+}
  ~ exitCode: 0 → 1
  ~ signal: null → SIGTERM

When the text matches but styling differs, you'll see ~ stdout styling changed.

See also

Source-available: CLI under FSL-1.1-ALv2, cloud server under BUSL-1.1. See Licensing.