Back to directory

dsh-turn-rewind

Curated pickMaintenance: Active

anionex/dsh-turn-rewind

消息锚定的工作区文件回滚/恢复(基于持久化 Change Ledger)

View on GitHub
$ dsh plugin --profile web add @anionex/dsh-turn-rewind

113

stars

10

forks

JavaScript

Language

BSD-3-Clause

License

2026-08-13

Created

2026-09-03

Last push

A DSH-native safety net that rewinds your workspace files to any prior user message, backed by the Change Ledger durable restore engine — explicit, human-approved, and Git-history-safe.

DSH integration

Native runtime

Author-claimed

Safety audit

Unaudited

Last verified

2026-08-25

License

BSD-3-Clause

01What can it help you accomplish?

  • Roll a DeepSeek Harness workspace back to exactly how it looked before a chosen user message

    A verified full or selective restore of worktree files, with an optional new Session that reopens the chosen message's prompt in the composer

    DSH users who want a manual, human-approved safety net against unwanted edits made by the agent, themselves, or external tools

  • Recover from a failed or interrupted restore and inspect Change Ledger rescue points

    An inspectable rescue point plus a plan/apply restore driven through the public `ctx.changeLedger` service API

    Operators and other Cordis plugins that need durable, auditable recovery of workspace mutations

02How to install into DeepSeek Harness

Prerequisites

  • A local checkout of the plugin repository (the install step builds the checked-out plugin)
  • Node.js and pnpm, to run `pnpm install --frozen-lockfile` and `pnpm run check`

Installation steps

  1. 01

    Build the checked-out plugin with `pnpm install --frozen-lockfile` then `pnpm run check`

  2. 02

    Add it to each DSH profile: `dsh plugin --profile web add @anionex/dsh-turn-rewind` (and `dsh plugin --profile headless add @anionex/dsh-turn-rewind`)

    $ dsh plugin --profile web add @anionex/dsh-turn-rewind

  3. 03

    Restart the running profile after changing its bundle list

Verify the integration

  • Confirm the bundle is registered: `dsh --profile web --dump-config | grep turn-rewind`
  • Open a user message in the Web profile and look for the icon-only Rewind action after its timestamp and Copy control

03DSH integration and capability boundaries

DSH integrationNative runtime

Ships as a DSH Profile Bundle (`dsh.bundle.patch`) mounted via `cordis.patch.yml` without a DSH core patch; enable it per profile with `dsh plugin --profile <name> add @anionex/dsh-turn-rewind`.

  • Turn Rewind user action

    a selected user message in a DSH Web sessiona preview of affected files and two restore choices — restore files and restart, or restore files only

    Restores selected worktree files only after you press the final confirm button in the Rewind dialog
  • Change Ledger durable restore engine

    the current Git worktree plus an agent, user, or external mutationcontent-addressed restore-point manifests and an exact path-level drift preview

  • Rescue points & recovery

    an interrupted or failed restore operationan inspectable rescue point and a plan/apply restore via the public `ctx.changeLedger` service API

    Captures a rescue point of the current tree before mutating any path
  • Configuration

    profile patch-layer overrides (storageDir, maxRestorePoints, maxFiles, maxFileBytes, etc.)resolved Change Ledger storage path and retention / size limits

  • Two restore modes

    restore-and-restart, or restore-onlyrestored project files, and optionally a new Session that puts the message's text back in the composer

04Who is it for? When not to use it?

Good for

  • DSH users who want a manual, human-approved safety net against unwanted edits made by the agent, themselves, or external tools
  • Operators and other Cordis plugins that need durable, auditable recovery of workspace mutations

Not for

  • Turn Rewind never touches Git history: the index, branch, HEAD, stash, and commits are left untouched, so restored content appears only as ordinary uncommitted changes.

05Compatibility, maintenance and safety notes

  • Turn Rewind never touches Git history: the index, branch, HEAD, stash, and commits are left untouched, so restored content appears only as ordinary uncommitted changes.
  • If an unmanaged or ignored file sits where a restore would write, the restore fails rather than deleting that file; sparse checkouts, submodule gitlinks, ignored files, special files, and non-Git directories are rejected.
  • Nothing is restored automatically. Every restore begins from you pressing the final button in the Web dialog or an explicit call through the service API; the dialog preview reads the tree but changes no files.
2026-08-132026-08-23v0.1.2

BSD-3-Clause · actively maintained (latest release v0.1.2, 2026-08-23)

06Frequently asked questions

What is DSH Turn Rewind, and how is it different from Change Ledger?

Turn Rewind is the user-facing Web action under each message; Change Ledger is the durable restore engine (`ctx.changeLedger` service, on-disk format, storage path) underneath it. The README calls Turn Rewind 'the user-facing feature, repository, and Profile Bundle name' and Change Ledger 'the durable restore engine underneath it.'

How do I install it into DeepSeek Harness?

Check out the repo, run `pnpm install --frozen-lockfile` and `pnpm run check`, then add it to each profile: `dsh plugin --profile web add @anionex/dsh-turn-rewind` (and the `headless` profile). Restart the profile afterwards, and confirm with `dsh --profile web --dump-config | grep turn-rewind`.

Does it modify my Git history or branches?

No. The safety contract states 'No Git control-plane mutation: the index, branch, HEAD, stash, and commits remain untouched.' Turn Rewind only restores worktree files after you confirm, so restored content shows up as ordinary uncommitted changes against the current HEAD.

What happens if a restore fails or DeepSeek Harness crashes mid-restore?

Before any write it captures a rescue point and a durable operation journal. If DSH stops with a non-terminal journal, the next startup marks it interrupted, and recovery uses the public `ctx.changeLedger` API — `listRecovery` finds the rescue point, `inspect` reviews it, then `planRestore`/`applyRestore` handle the paths.

Which files can it restore, and what is out of scope?

In v0.1 it supports normal Git worktrees only: tracked files (including missing ones), untracked non-ignored files, symlinks, binaries, and permission bits. It rejects sparse checkouts, submodule gitlinks, ignored files, special files, and non-Git directories; an ignored file in a restore path makes the restore fail rather than delete it.

08Data and sources

  • Author-claimedgithub.comd3734cb183a5…

    The package is a DSH Profile Bundle. `package.json` declares `dsh.bundle.patch`, and `cordis.patch.yml` mounts `@anionex…

  • Author-claimedgithub.comd3734cb183a5…

    Message-anchored project-file recovery for [DeepSeek Harness](https://github.com/deepseek-ai/deepseek-harness), with an…

This page is generated from the project’s public documentation, repository metadata and a structured parse of DSH Plugins; last verified on 2026-08-25. Found an error? Submit a correction.

🏆

Best DeepSeek Harness Plugins

Twelve plugins worth installing first — picked from the whole catalog, across every category.

DSH Plugins is an independent community directory of DeepSeek Harness plugins. Not affiliated with or endorsed by DeepSeek. Third-party plugins are not security-audited — review the source before installing.

New DeepSeek Harness plugins, weekly. No spam.