UndoHaven · Pricing · Docs · Plugins · Log gate · Encryption · What we see · Log in · Account · 中文

Where DSH_HOME and DSH_AGENTS_HOME live, and how to copy them

dsh resolves two roots with os.homedir(). DSH_HOME defaults to ~/.dsh. DSH_AGENTS_HOME defaults to ~/.agents. An empty or blank variable counts as unset, so the root does not become the current directory. On Windows the usual path is %USERPROFILE%\.dsh, and the desktop notes say this is not the Electron folder under %APPDATA%. Termux uses the same rule: echo "$HOME" on that device. The desktop shell settings file is separate and is not the session store.

Fix it by hand

  1. Quit dsh, dsh web, and the desktop app. Then: ls -ld "${DSH_HOME:-$HOME/.dsh}" "${DSH_AGENTS_HOME:-$HOME/.agents}".
  2. From the home directory, tar those two names and exclude cache, logs, storages/session_projcache, profiles/*/node_modules, .credentials.yaml, .env, and session.lock. If DSH_HOME is not ~/.dsh, pack the real directory instead of the name .dsh.
  3. On Windows 10 or later, tar exists, but this exclude list was not run on Windows here. Keep the archive private.
  4. Sessions are $DSH_HOME/sessions, as session.vN.jsonl.zstd. Profile config is $DSH_HOME/profiles/<name>/cordis.patch.yml. Shared skills are under $DSH_AGENTS_HOME.

No official backup command was found in the sources checked through tag dsh-v0.2.2-rc.3. The tar line is assembled from those paths. Uninstalling the desktop app does not delete ~/.dsh.

Optional encrypted snapshot

Optional. UndoHaven is an unofficial third-party, compatible with dsh. Copy the directory by hand first, then use an encrypted snapshot if you want one.

npx undohaven init

  1. Install: copy this command.
  2. First snapshot: it stays encrypted on this machine.
  3. Roll back: undohaven restore --to SNAPSHOT_ID

Free covers 7 days of history and 1 device. Pricing

Related