Skip to content

xiaoyuyu6420/dsh-backup

31Last commit Aug 15, 2026

dsh-backup DSH plugin

dsh-backup is a DSH plugin that backs up and restores the entire ~/.dsh directory (sessions, settings, credentials, skills, plugin config) excluding node_modules. It supports manual backup, scheduled auto-backup, archive integrity verification, GitHub sync, and a visual web panel in the DSH Settings → Plugins tab.

How to install the dsh-backup DSH plugin

dsh plugin --profile web add dsh-backup

Copying does not run this command. Review the repository and version before installing the dsh-backup DSH plugin.

dsh-backup DSH plugin data source

dsh-backup DSH plugin snapshot date: Aug 16, 2026

discovered

What the dsh-backup DSH plugin can do

  • Immediate backup of ~/.dsh to a timestamped tar.gz archive on the desktop.
  • Restore from any archive with integrity checksum verification and path traversal protection.
  • Scheduled auto-backup every N hours (1–720) with rotation (keeps 3 copies under 24h, 7 otherwise) that survives restarts.
  • GitHub sync: push archives to a private Git repository with force-with-lease and credential isolation.
  • Web panel (Backup tab) for one-click backup, verify, download, and restore with dry-run preview.
  • List existing backups with size, verify checksum, and view auto-backup status via commands.

Where the dsh-backup DSH plugin fits

  • Regularly backup your DSH environment before trying risky plugins or config changes.
  • Restore your entire DSH setup after a system crash or reinstall.
  • Automate nightly backups to a GitHub private repo for offsite redundancy.
  • Verify backup integrity to ensure your data is not corrupted before a restore.
  • Use the web panel to manage backups visually without remembering commands.

Who the dsh-backup DSH plugin is for

  • Power users who frequently customize DSH plugins and want to protect their configuration.
  • Developers deploying DSH in production or multi-instance setups requiring reliable backup workflows.
  • Anyone who wants a simple, automated backup solution for their DSH data across platforms.

dsh-backup DSH plugin limitations

  • Backups contain plaintext credentials – never sync to public repositories or untrusted locations.
  • Auto-backup only works on the machine where it was configured; GitHub sync requires a private repo and a token set via environment variable.
  • Restore completely replaces current ~/.dsh – no merge support; current state is moved aside as a snapshot.
  • Requires tar in PATH (Windows works with bsdtar or Git Bash's GNU tar).
  • Archives larger than 90 MB are skipped during GitHub sync with a notice.

dsh-backup DSH plugin: from the repository README

Quoted from the xiaoyuyu6420/dsh-backup README, the upstream source of the dsh-backup DSH plugin. Copyright remains with the original authors.

One-command backup **and restore** for DeepSeek Harness user data — sessions, settings, credentials, skills, and plugin config under `~/.dsh`, excluding reinstallable `node_modules` — with sha256 checksums, integrity verification, automatic rotation, and scheduled auto-backup that survives restarts. Works on macOS, Linux, and Windows. ## Commands - **`/backup`** — immediately back up `~/.dsh` to `~/Desktop/dsh-backups/dsh-<timestamp>.tar.gz` - **`/backup list`** — list existing backups (name + size) and auto-backup status - **`/backup verify [prefix|all]`** — validate archive checksums (default: the newest) - **`/backup restore <prefix|latest> [--dry-run]`** — restore `~/.dsh` from an archive - **`/backup auto <N>|off|status`** — auto-backup every N hours (1–720; keeps 3 copies below 24h, 7 otherwise; persisted across restarts) - **`/backup --keep N`** — override the rotation count (default 7) - **`/backup github status|sync`** — GitHub sync status / push now - **`backup_dsh` tool** — same capability for the model (`mode=backup|list|verify|restore|auto`) ## GitHub sync With `config.githubRepo` set, every backup (manual, automatic, or panel) is also pushed to a Git repository —

Read the full READMERepository license: MIT

dsh-backup DSH plugin questions

How do I install dsh-backup?

Run `dsh plugin --profile web add dsh-backup` in your terminal. Then restart `dsh web` to activate the plugin. You can verify installation by running `/backup` in the chat or checking the Backup tab in Settings → Plugins.

Where are backups saved by default?

Backups are saved to `~/Desktop/dsh-backups/` by default. You can change the destination by setting the `destination` config option in your cordis profile. For example, `config: { destination: '~/Backups/dsh' }`.

Can I automate backups to run every hour?

Yes, use `/backup auto <N>` where N is the interval in hours (1–720). For example, `/backup auto 1` sets hourly backups. The auto-backup state persists across restarts and you can check status with `/backup list` or `/backup auto status`.

How do I restore a backup if something goes wrong?

First, run `/backup list` to see available backups. Then use `/backup restore <prefix|latest>` to restore. Always try `--dry-run` first to preview what will be restored. The restore process checksums the archive, guards against path traversal, snapshots the current ~/.dsh, and then extracts the archive. After restore, restart `dsh web` to apply the changes.

Is it safe to use GitHub sync?

GitHub sync pushes backups to a private repository. You must set a private repo and provide a token via `DSH_BACKUP_GITHUB_TOKEN` or `GITHUB_TOKEN` environment variable. Archives contain plaintext credentials, so never use a public repo. The plugin uses `--force-with-lease` and keeps credentials only in the worktree's credential file, not in process args.