undomap

DOCS · SHEET 04 OF 06

Configuration

.undomap.json

Optional, at the root you map (or pass --config file). It tells undomap what it can't detect.

{
  "permanent": ["build/atlas/", ".cache/models/", "vendor/patched/"],
  "regenerable": ["generated/", "*.parquet", "data/cache/**"],
  "backedUp": ["media/", "Rushes/"]
}

Precedence

When rules disagree, the first one that applies wins:

  1. What git knows. Clean tracked files are Zone X and uncommitted edits or unpushed commits are Zone AE, whatever the config says. permanent can't make git forget a commit.
  2. Real coverage. backedUp, a snapshot that covers the path, and cloud version history undomap could verify move it to Zone AE, even if it's also permanent: a copy really exists somewhere else. The reason says both ("marked permanent, but backed up per .undomap.json").
  3. permanent beats every "regenerable" guess: built-in folder names (dist, .cache, vendor…), content markers (pyvenv.cfg, CACHEDIR.TAG, ELF/Mach-O/PE headers) and your own regenerable list. If a path is on both of your lists, permanent wins.
  4. Regenerable (built-in or yours): Zone AE.
  5. Everything else git doesn't hold: Zone VE.

Pattern rules: dir/ matches that directory at any depth, or anchored if it contains another slash (a/dir/). *.ext matches a basename. a/**/b matches across directories. Unknown keys are an error, so a typo can't silently grade your data as safe.

Flags

FlagDefault
--fixofffix under every Zone VE place (otherwise only the biggest)
--json / --markdowntextoutput format
--alltop 12list every Zone VE place
--max-permanent <size>0permanent bytes allowed before exit 1: 512KB, 10MB, 1.5GB
--config <file><path>/.undomap.jsonconfig file
--reachoffadd the credential reach section: live credentials + network + writes outside the tree. Names and paths only, never values. Doesn't change the exit code
--no-probeprobeskip snapshot and cloud-sync probes (UNDOMAP_CLOUD=off skips only the cloud one)
--no-colorautoalso NO_COLOR=1. FORCE_COLOR=1 forces color in pipes

Exit codes

0nothing in Zone VE (or under --max-permanent)
1something in Zone VE
2usage error, unreadable root, invalid config

Next sheet: Reference