mantish/ help / docs
Join the waitlist

Diff profiles

Reusable, shareable JSON settings for mantish diff — for your team and for your agent.

Last updated

A profile is a JSON file holding the settings you would otherwise type every time.

sh
mantish diff --profile review
mantish diff --profile ./team-diff.json
mantish diff --no-profile            # read no profile and no config.json

Where profiles live

Two directories, searched in this order:

  1. <repo root>/.mantish/profiles/ — the repository's own, committed and shared with the team. Mantish never shows .mantish/ as a change in its own review.
  2. ~/.mantish/profiles/ — yours, on this machine (%LOCALAPPDATA%\Mantish\profiles\ on Windows, $MANTISH_HOME/profiles/ when set).

--profile review is a name: it resolves to review.json in the first directory that has it. Anything containing a path separator, ending in .json, or starting with . or ~ is a path. Names may not contain #, /, \ or whitespace.

  • A relative --profile path resolves against the directory you ran the command in, before -C.
  • A relative defaultProfile path resolves beside config.json.
  • ~/ is expanded. Environment variables, ~otheruser and globs are not.

The file

json
{
  "version": 1,
  "format": "auto",
  "context": 3,
  "width": 160,
  "stats": false,
  "muteTags": ["formatting", "import"],
  "hideTags": [],
  "spotlightTags": ["breaking", "error-handling"],
  "view": "unified",
  "whitespace": "trim",
  "ignore": ["letter-case"],
  "collapse": true,
  "words": true,
  "syntax": true,
  "showMuted": false
}
FieldValues
versionRequired, 1
formatauto, tui, diff, json, side-by-side, markdown
context0 – 10 000 (text formats)
width40 or more (side-by-side)
statsBoolean: write counts, coverage and hunk annotations (diff, side-by-side, markdown)
muteTags, hideTags, spotlightTagsArrays of tag ids
viewsplit or unified (the review screen)
whitespaceexact, trim, ignorewhitespaceandempty
ignoreArray of letter-case, punctuation, typos; [] ignores none
collapse, words, syntax, showMutedBooleans (the review screen)

Every field is optional. A profile may hold settings for several formats; only the relevant ones are applied, so width in a profile does not break a --format json run — but passing --width explicitly with json still fails.

A profile holds display and filtering preferences only. There are no repository targets, engine commands, credentials, includes, or references to another profile.

Errors you might hit

  • version missing or not 1.
  • An unknown key — refused, with a suggestion if it is within a typo's distance (muteTag → muteTags).
  • A repeated key anywhere in the file.
  • null as a value — write the field or leave it out.
  • An unknown or disallowed tag id, in any file that was loaded, even one a higher layer replaces. A typo shadowed today would surface the day that layer changes, far from its cause.

Two profiles to copy

review.json — for reading changes yourself:

json
{
  "version": 1,
  "format": "auto",
  "view": "split",
  "whitespace": "trim",
  "muteTags": ["formatting", "whitespace", "import", "comment"],
  "spotlightTags": ["breaking", "error-handling", "disabled-test"],
  "syntax": true,
  "words": true
}

agent.json — for a coding agent, see Coding agents:

json
{
  "version": 1,
  "format": "diff",
  "context": 3,
  "whitespace": "exact",
  "muteTags": [],
  "hideTags": ["whitespace", "formatting", "code-style", "syntax-sugar", "indentation"],
  "spotlightTags": ["breaking", "error-handling", "type-change"]
}
Was this page helpful?