nuwa-skill
alchaincyf
你想蒸馏的下一个员工,何必是同事。蒸馏任何人的思维方式——心智模型、决策启发式、表达DNA。Distill how anyone thinks.
blankwy/dsh-workspace-relink
Workspace routing migration for DeepSeek Harness. Move a project folder, then repoint its workspace at the new location — the conversations that lived in the old folder keep working, without a single byte of session history being rewritten.
PROJECT TOPICS
INSTALL REFERENCE
dsh plugin --profile web add github:blankwy/dsh-workspace-relink
该命令指向仓库当前默认分支;尚无绑定当前 commit 的完整验证结果。
PROJECT README
English | 中文
Workspace routing migration for DeepSeek Harness. Move a project folder, then repoint its workspace at the new location — the conversations that lived in the old folder keep working, without a single byte of session history being rewritten.
A DSH workspace is one registry record pointing at one directory, and a stored
session is grouped into a workspace by the canonical form of cwd recorded in
its immutable header. Move the files and both halves break at once:
missing-dir;There is no relocation API — the header is append-only storage — so the only honest fix is to make the old directory spelling resolve again while the workspace record moves to the new canonical path. That is exactly what a directory route (a Windows directory junction) does, and it is why this plugin is about routing, not about editing history.
D:\A\B\C ──► moved by you to ──► D:\E\F\A\B\C
│ │
└── becomes a junction ───────────────┘
(workspace record now lives here)
工作区路由迁徙 (Plugins → the plugin's page) plans the move: it checks the new
directory, says whether the old path is free, and lists what it will do.The same page can move a single conversation into another workspace, and manages the junctions it created (inspect them, remove them).
fs.symlink(..., 'junction')).<name>.moved-<timestamp>; nothing is deleted.cwd are reported as untransferable rather than
guessed at.Plugins → 工作区路由迁徙.
修改位置 → new path, 浏览…, 预览计划, 执行迁徙, with
blockers and warnings spelled out before anything is written.Available to the model unless agentTools is false:
| Tool | Purpose |
|---|---|
workspace_relink_status |
Workspaces, paths, status, session counts, recorded routes. includeSessions: true also returns each session's id, title, recorded cwd, cwdState and live flag |
workspace_relink_plan |
Dry run for repointing one workspace |
workspace_relink_apply |
Execute it (confirmed: true required) |
workspace_relink_move_session |
Move one conversation into another workspace |
workspace_relink_route_remove |
Remove one recorded route |
Every tool answers with a one-line human summary plus the full JSON payload as a
second text block, so the model can read plan.blockers[].code, workspace ids and
session titles instead of guessing from prose.
| Key | Default | Meaning |
|---|---|---|
agentTools |
true |
Expose the tools above to the model; the page always works |
allowSessionRoutes |
true |
Allow creating a route when moving a conversation whose directory is gone |
Routes this plugin created are recorded in
<DSH_HOME>/workspace-relink/routes.json (absolute paths, kind, ids, timestamp).
It is an index over the filesystem, never the authority: a hand-made symlink is
never touched, and a recorded route whose link is gone is simply reported.
node scripts/selftest.mjs
The harness exercises the engine against a stand-in registry that reproduces
DSH's membership canon (realpath(header.cwd) equality, plus the missing-cwd
wildcard): broken state, plan, apply, route reuse, refusal cases, leftover
directory displacement, single-session adoption, and route removal. It writes
nothing outside a temporary directory.
MIT © dsh-workspace-relink contributors
CLASSIFICATION EVIDENCE
系统优先读取 GitHub Topics,再与站内分类词典和词根规则比对。当前命中: session、history。