返回目录
Agent 与会话 插件

dsh-workspace-default-path

masknull/dsh-workspace-default-path

DSH 插件:添加工作区时记住上次使用的目录,下次打开浏览对话框直接定位(预填 + 自动记忆,官方流程不动)。 | DSH plugin: remember the last used workspace directory for Add workspace - prefill + auto-memory over the official flow.

Stars
0
Forks
0
Issues
0
更新
2 个月前

PROJECT TOPICS

项目标签

INSTALL REFERENCE

安装参考

未验证
dsh plugin --profile web add github:masknull/dsh-workspace-default-path

该命令指向仓库当前默认分支;尚无绑定当前 commit 的完整验证结果。

PROJECT README

README

dsh-workspace-default-path

中文版:README.zh.md · DSH (DeepSeek Harness) plugin

Remember the last used workspace directory for the Add workspace flow (sidebar / conversation empty-state). Two lightweight hooks over the official flow — nothing is replaced, and the whole thing is a single on/off toggle in Settings → General.

Features

  • Remember — every workspace you add (from the browse dialog, the system dialog, or any other entry) is recorded automatically.
  • Prefill — with a remembered path, the official "Add workspace" browse dialog opens directly on the last used directory, breadcrumb path bar included; all browsing, editing and confirm interactions stay 100% official.
  • Off = stock — with the toggle off, both hooks are inert: no redirection, no recording, identical to an uninstalled plugin.
  • Hot-reloadable — the toggle persists to $DSH_HOME/settings.yaml (dsh-workspace-default-path.rememberLast / .lastPath) and applies immediately, no restart.

Install

From GitHub (standard, same as any other dsh plugin dependency):

dsh plugin --profile web add github:masknull/dsh-workspace-default-path

The package declares dsh.bundle, so the command also activates it (adds it to the profile's dsh.profile.bundles). If it is not auto-added, append "dsh-workspace-default-path" to that list in $DSH_HOME/profiles/web/package.json manually.

Runtime deps of the node half (@deepseek-ai/schemastery + cosmokit + @standard-schema/spec) are declared in dependencies, so pnpm resolves them into the profile's hoisted node_modules automatically — no manual copying.

Verify:

dsh --profile web --dump-config | grep workspace-default-path

Restart the web service after install or any code update (client HMR is disabled in the current web composition). Local development works the same way: dsh plugin --profile web add '<local-path>'.

Usage

  1. Open Settings → General → "Remember last workspace" → On.
  2. Add a workspace as usual (any method). Its path is remembered.
  3. Next time you click Add workspace, the dialog opens on that directory.
  4. Toggle Off anytime to restore the default behavior.

How it works

All over official seams; no official interaction is replaced.

Hook Mechanism
Remember (write) Subscribes to ctx.workspaces.list; any newly appearing workspace's path is written to lastPath
Prefill (read) The browse dialog opens with listDirectory(undefined) (host home). When remembering is on and lastPath exists, that initial call is redirected to listDirectory(lastPath); all other calls pass through untouched

Version compatibility

  • v0.2.0+ requires DSH ≥ dsh-v0.1.2-alpha.1: that release moved the snapshot-store primitives from @deepseek-ai/dsh-client-runtime/client into the frozen module-table word @deepseek-ai/dsh-client-store. On older hosts this plugin refuses to load with a clear diagnostic; use the v0.1.x line (built for the client-runtime era) there.
  • Needs @deepseek-ai/dsh-client-ui-workspace for the workspaces/browse-dialog services (built into current DSH).

Dependencies

  • Node half (lib/index.js): @deepseek-ai/schemastery (+ @deepseek-ai/cosmokit, @standard-schema/spec) — declared in dependencies, installed by pnpm on add.
  • Browser half: only official frozen-module-table entries (react, @deepseek-ai/dsh-client-store, @deepseek-ai/dsh-client-ui-primitives).

License

MIT.

CLASSIFICATION EVIDENCE

分类依据

项目类型插件
功能分类Agent 与会话
规则置信度中

系统优先读取 GitHub Topics,再与站内分类词典和词根规则比对。当前命中: memory、记忆。