Environment variables

Environment variables

The environment variables the loot binary reads. Settings you want to keep belong in config instead.

VariableWhat it doesWhen unset
LOOT_PASSPHRASEThe custody passphrase for a passphrase-locked repo. Every verb that opens such a repo tries it first, before any loot unlock session. loot init locks the new repo with it, loot id lock sets it as the new passphrase, and loot unlock checks it. A wrong value is ignored and the unlock session is tried instead; with no session, every verb that reads content refuses. Empty counts as unset. loot id export, loot id import and loot clone --identity-file also take it as the export file’s passphrase, and loot login with no terminal as the forge key passphrase, unless --passphrase-file <file> names a file whose first line is that passphrase and which only you can read.The unlock session, if there is one. init, id lock, unlock, id export and id import prompt on a terminal, and with no terminal refuse at once.
LOOT_SESSIONNames the session that owns the lanes you spawn. loot lane gc sweeps only this session's lanes and loot lane rm refuses another's, unless --reap-others. A label, not a security boundary.A label generated per run, so no later run matches your lanes.
LOOT_SEEK_CACHEDirectory for the caches loot seek keeps of remote targets, such as a git URL.loot/seek under the cache base (below).
LOOT_SEEK_CACHE_CAPByte cap on that cache, applied after each refresh and by loot seek --gc, where --cap overrides it. 0 means no cap.2 GiB
LOOT_RUNNER_FORGE, LOOT_RUNNER_NAME, LOOT_RUNNER_CAN, LOOT_RUNNER_PUBKEY, LOOT_RUNNER_KEYThe runner home for loot runner once and loot runner serve without --home: the same keys as the home file loot runner add writes. LOOT_RUNNER_KEY is the runner's private key.Required unless you pass --home.
LOOT_AGENT_KEYAn agent key, the line loot agent add hands over. It is a private key. Only loot agent self, files, cat and propose read it.Those four refuse unless you pass --key-file.
LOOT_NO_MACHINE_KEYSet to anything, loot ignores the account key loot login keeps for this machine: loot init and loot clone mint a fresh key, and loot login outside a repo refuses.The machine's account key is used if there is one.
LOOT_NET_TIMING1 prints one line per network request on stderr: method, path, status, timings, bytes and host. Any other value is off.Off
LOOT_CLOCKUnix seconds that replace the clock this process reads, for testing. It cannot reveal someone else's embargoed content early: that key is not on your machine until the relay releases it on its own clock.The system clock
XDG_CONFIG_HOME, HOME, USERPROFILELocate the config base: $XDG_CONFIG_HOME, else $HOME/.config, else %USERPROFILE%\.config. Its loot/ directory holds the global config, the unlock session, this machine's account key and the telemetry spool.~/.config
XDG_CACHE_HOMEThe cache base for loot seek, with the same HOME and USERPROFILE fallbacks.~/.cache
TMPDIR (TMP or TEMP on Windows)Where loot writes short-lived scratch files, each removed after use: the sides loot resolve --tool hands your merge tool, which are decrypted plaintext; a gate's message file; pipeline scratch trees; and the tutorial's repos.The OS temp directory

Variables loot sets

  • loot resolve --tool <cmd> runs your merge tool with LOOT_BASE, LOOT_OURS, LOOT_THEIRS and LOOT_OUTPUT set to the base, your side, their side and the file to write the result to. The command string also expands $BASE, $LOCAL, $REMOTE and $MERGED to the same paths. A nonzero exit or an empty result leaves the conflict unresolved; a zero exit with the result file removed resolves the path as deleted.
  • loot seek runs git with GIT_TERMINAL_PROMPT=0, so a git URL never stops to ask for credentials.
  • loot tutorial points HOME and XDG_CONFIG_HOME into its temp tree and removes LOOT_PASSPHRASE, so its throwaway repos never touch your config or your passphrase.