import { homedir } from 'node:os'; import { join } from 'node:path'; /** The directory host-owned state lives under — rate-budget ledgers, the branch-ancestry lock and * removals, the shared blob index, World lifecycle records: `VOLTER_HOME`, else `~/.volter`. A * verification run points it at a directory of its own (scripts/isolated-home.ts), so a run * spends no other actor's allowance and deletes none of their records. Read on every call. */ export function volterHome(): string { const set = process.env.VOLTER_HOME; return set !== undefined && set !== '' ? set : join(homedir(), '.volter'); }