PPsz-qqq/dsh-restart-button
DeepSeek Harness plugin: one-click restart button in the top-right of the session header (Windows desktop + dsh web). 一键重启 DeepSeek Harness 客户端。
Project Overview项目介绍
dsh-restart-button is a native plugin built specifically for DeepSeek Harness (DSH), shipping a bundle-manifest package whose entire purpose is to add a single restart button (↻) at the far right of the conversation header utility area (conversation.session.header.utilities, order 1000). It is installed from inside DSH itself: open the Plugins page, pick a source such as the dshmarket listing "dsh-restart-button" by PPsz-qqq, paste a GitHub Release .tgz URL (releases/latest/download/dsh-restart-button.tgz for the floating latest, or releases/download/v0.2.0/dsh-restart-button-0.2.0.tgz for a pinned version), use the shorthand github:PPsz-qqq/dsh-restart-button#v0.2.0, point at a local .tgz, or have an Agent call plugin_manager install_bundle. The first install takes effect immediately without a restart, while any later upgrade does require a single restart because Node caches loaded modules in-process.
When the button is clicked, the client POSTs to api/restart-button.restart through DSH's standard Host/Origin and browser-side authentication, and the Host records currently open and in-flight sessions to ~/.dsh/restart-button/last-restart.json so the next Host can resume them. A detached helper (detach.mjs invoking restart-desktop.ps1 on Windows) then verifies the Electron main process and Host by executable path and parent/child relationship, suspends the main process so it never notices the Host exiting — preventing crash dialogs and crash dumps — and finally re-launches DeepSeek Harness.exe with the original arguments once port 19387 is free. A second mode, "restart when idle," polls every second and fires the same pipeline only after three consecutive seconds with no running agent turn, queued message, or background job, followed by a 1.5-second grace period so the page can render a "restarting" state.
The desktop one-click path is currently Windows-only; on macOS and Linux desktop builds the button hides itself automatically, while dsh web restarts its service process and redirects logs to ~/.dsh/logs/restart-button-web-server.log. The confirm policy is tunable through cordis.patch.yml with values when-busy (default), always, or never, and the button surfaces runtime duration, memory footprint, busy session count, scheduled restart state, and pending plugin updates on hover, plus an orange dot and a "plugin update pending" card after in-place upgrades. The recovery banner is only valid for ten minutes after restart, scheduled restarts live only inside the current Host process, and all failures are written to ~/.dsh/logs/restart-button.log under an MIT license.
dsh-restart-button 是一款面向 DeepSeek Harness(DSH)的原生插件,专门在会话标题栏最右端添加一个「重启」按钮(↻)。安装方式包括:在 DSH「插件」页搜索 dshmarket 条目、填写 GitHub Release 的 .tgz 链接(latest/download/dsh-restart-button.tgz 或带版本的 dsh-restart-button-0.2.0.tgz)、填写 github:PPsz-qqq/dsh-restart-button#v0.2.0,或让 Agent 调用 plugin_manager install_bundle。第一次安装立即生效,无需重启;之后升级则必须重启一次,以让 Node 重新加载新模块。
点击按钮会调用 POST api/restart-button.restart,经过 DSH 自带的 Host/Origin 与浏览器鉴权,写入 ~/.dsh/restart-button/last-restart.json,再启动脱离进程树的辅助脚本(detach.mjs → restart-desktop.ps1)。辅助脚本核对 Electron 主进程与 Host 的可执行路径和父子关系,挂起主进程使它不感知 Host 退出,最后用原参数重启 DeepSeek Harness.exe。忙碌时支持「跑完后重启」(每秒检查,连续 3 秒无 Agent 回合、排队消息或后台作业后再等 1.5 秒便触发)。重启后自动恢复原会话,可一键「全部继续」。
平台限制:桌面版一键重启仅支持 Windows,macOS / Linux 桌面版按钮自动隐藏;dsh web 模式下日志写入 ~/.dsh/logs/restart-button-web-server.log。按 confirm 配置项(when-busy / always / never)控制确认策略。悬停按钮可查看运行时长、内存、活跃会话数、已安排重启和待生效插件更新;升级时按钮显示橙色小点并弹出更新卡片。日志位于 ~/.dsh/logs/restart-button.log。许可证:MIT。
请帮我安装这个 DSH 插件。安装前先完成【兼容性检查 + 安全性检查】,检查通过再动手。
插件:dsh-restart-button(PPsz-qqq/dsh-restart-button)
仓库:https://github.com/PPsz-qqq/dsh-restart-button
本站详情页:https://www.yhbd.top/plugins/ppsz-qqq-dsh-restart-button/
本站登记:类型 client · 归类 原生 DSH 插件 · 许可证 MIT · ⭐ 3 · 最近提交 2026-10-03 · 主语言 JavaScript
按下面顺序执行,每步先把结论告诉我,再进入下一步:
【1 兼容性检查】
① 我这边:DSH 版本、Node 版本、操作系统、当前 profile(web / desktop)。
② 读它的 README、package.json、插件 manifest,列出它要求的 DSH 版本 / Node 版本 / 操作系统 / 外部依赖 / 需要另外先装的运行时。
③ 逐条比对,结论只写「满足 / 不满足 / 未知」三种;不满足的给出可行替代方案。
④ 检查是否和我已装的插件冲突:命令名重复、skill / tool 重名、端口占用、重复注册的 MCP server。
【2 安全性检查】
① 仓库可信度:和上面「本站登记」是否一致;star / fork 数、创建时间、最近提交,是否归档或长期停更。
② 安装脚本:逐行看 package.json 的 preinstall / install / postinstall,以及 install.sh、setup.ps1 之类脚本。出现 curl|bash、下载后直接执行、混淆代码、访问与插件功能无关的域名,立刻停下来告诉我,不要继续装。
③ 依赖:列出新增依赖,标出无人维护、或与知名包拼写近似的可疑包(typosquatting)。
④ 权限与副作用:它会读写哪些目录、访问哪些域名、需要哪些 DSH 权限(filesystem / network / shell / clipboard 等),以及怎么卸载和回滚。
⑤ 如果它要求 sudo / 管理员权限,或权限明显超出功能所需,先停下来问我。
【3 安装】
上面两步没有「不满足」和「高危项」时才执行;用官方推荐方式安装,不要自行提权。
【4 汇报】
用表格输出:检查项 / 结论 / 依据 / 是否需要我决策。拿不准的一律写「未知」并说明要我怎么确认——不要猜,也不要替我决定。
Send this message to DSH in your current session: it verifies compatibility and security first (answering met / not met / unknown item by item) and only installs once everything checks out — it will stop and ask you if it finds a high-risk item. The box scrolls; the copy is the full prompt. CLI install commands may not be accurate across systems, so DSH is the safer route.把上面这条消息直接发给当前会话里的 DSH:它会先核对兼容性与安全性(逐条给「满足 / 不满足 / 未知」),确认没问题再安装,有高危项会停下来问你。框内可滚动,复制到的是完整提示词;安装命令不一定准确,发给 DSH 更稳。
- Only 3 stars - very few users, little community feedback星标只有 3,几乎没人在用,遇到问题缺少社区反馈
- Desktop client: installation downloads an executable - verify the publisher and checksums桌面客户端:安装会下载可执行文件,请核对发布者与校验和
DSH walks through these 9 checksDSH 会逐条核对这 9 项
Compatibility兼容性
- DSH, Node, OS and profile requirementsDSH 版本 / Node 版本 / 操作系统 / profile 是否满足要求
- External dependencies and runtimes (Electron / Python / Docker, ...)外部依赖与运行时(Electron / Python / Docker 等)是否齐备
- Conflicts with installed plugins: command names, skill / tool names, ports, duplicate MCP registration与已装插件是否冲突:命令名、skill / tool 重名、端口占用、重复 MCP 注册
Security安全性
- Repo matches the facts registered here; archived or abandoned?仓库是否与页面登记一致,是否归档或长期停更
- Safety of preinstall / install / postinstall and install.sh / setup.ps1preinstall / install / postinstall 与 install.sh、setup.ps1 是否安全
- curl|bash, download-then-execute, obfuscation, unrelated domains → stop immediatelycurl|bash、下载即执行、混淆代码、无关域名 → 立刻停止
- Typosquatting or unmaintained packages among the new dependencies新增依赖里有没有 typosquatting 或无人维护的包
- Requested permissions vs. what the feature actually needs申请了哪些权限、是否超出功能所需(filesystem / network / shell / clipboard)
- Any sudo / admin requirement, plus uninstall and rollback是否要求 sudo / 管理员权限,以及卸载与回滚方式
Anything uncertain must be marked unknown with a note on how to confirm it. This site's signal screen is a static snapshot, not a security audit.拿不准的必须标「未知」并说明要我怎么确认。本站的信号筛查是静态快照,不能替代安全审计。
Or use CLI install (for developers)或使用命令行安装(适合开发者)
CLI Install命令行安装
dsh plugin --profile web add github:PPsz-qqq/dsh-restart-button
把 PPsz-qqq/dsh-restart-button 加入你的 DSH 配置(web profile)即可启用。
READMEREADME
dsh-restart-button
在 DeepSeek Harness 会话标题栏的右上角加一个「重启」按钮(↻),点一下就能安全地重启整个客户端。
Adds a restart button (↻) to the top-right of the DeepSeek Harness session header. One click restarts the whole client safely.

功能
- 位置:会话标题栏右侧工具区的最右端(
conversation.session.header.utilities,order 1000),紧挨右侧边栏开关。 - 一键重启:没有任务在运行时直接重启。
- 跑完后再重启:有会话正在运行或后台作业未结束时,确认框里多一个「跑完后重启」。选它之后按钮变成蓝色并带一个闪烁的小点,所有任务结束后自动重启;再点按钮可以「取消安排」或「立即重启」。
- 重启后接着干:重启前会记下你当前打开的会话和被中断的会话。重启完成后自动回到原来的会话,并弹出卡片「重启前有 N 个会话正在运行」,点「全部继续」就向这些会话发送"继续",也可以逐个点开。
- 插件更新提醒:插件被原地更新(升级或重装)后,新代码要重启才会加载。插件会发现这种情况,在按钮上显示一个橙色小点,并弹出卡片「插件更新待生效:名称 旧版本 → 新版本」,可以「立即重启」或「稍后」。
- 悬停查看运行状态:鼠标放在按钮上会显示 Host 已运行多久、占用多少内存、几个会话正在运行、是否已安排重启、有几个插件更新等待生效。
- 桌面版(Windows):重启 Electron 外壳和后台 Host,新窗口自动打开,参数与原来一致。
- dsh web:重启服务进程,页面在服务恢复后自动刷新。
- 失败时弹窗说明原因,并给出日志路径
~/.dsh/logs/restart-button.log。
工作原理(桌面版)
DeepSeek Harness 桌面版由 Electron 主进程启动一个 Node 模式的 Host 子进程(它跑插件、会话和 Web 服务)。 点击按钮后:
- 浏览器端向
POST api/restart-button.restart发请求(走 DSH 自带的 Host/Origin 校验和浏览器鉴权)。 - Host 把当前会话和正在运行的会话写进
~/.dsh/restart-button/last-restart.json,供重启后的 Host 读取。 - Host 启动一个脱离进程树的辅助程序(
detach.mjs→restart-desktop.ps1),由它核对 Electron 主进程和 Host 的身份(可执行文件路径、父子关系)。 - 辅助程序挂起 Electron 主进程,使它察觉不到 Host 退出(不会弹出崩溃对话框、不会写崩溃报告)。
- Host 断开与主进程的 IPC,走的正是桌面版退出时的同一条优雅关闭路径:会话落盘、插件逐个释放。
- Host 退出后,辅助程序结束被冻结的主进程及其残留子进程,等端口 19387 释放后,用原来的参数重新启动
DeepSeek Harness.exe。
任何一步出错都会记录到日志;若在挂起后失败,辅助程序会恢复主进程,不会留下卡死的窗口。
「跑完后重启」由 Host 每秒检查一次:连续 3 秒没有运行中的 Agent 回合、排队消息或后台作业,就按上面的流程重启(会先留 1.5 秒让页面显示"正在重启")。
「插件更新提醒」的判断方法:Host 记下本进程加载过的每个插件的版本和来源。Node 会缓存已加载的模块,所以之后磁盘上的版本或来源一旦变化(原地更新,或先移除再安装),都算待生效;本进程从未加载过的新插件会直接热加载,不算。
配置
可在 profile 的 cordis.patch.yml 中调整确认策略:
- id: restart-button
config:
confirm: when-busy # when-busy(默认,仅在有任务运行时确认)| always(总是确认)| never(从不确认)
安装
在 DeepSeek Harness 的「插件」页面点「安装」,填入下面任意一种来源(也可以让 Agent 用 plugin_manager install_bundle 安装同样的来源):
| 来源 | 填写内容 |
|---|---|
| 插件市场 dshmarket | 搜索 dsh-restart-button(作者 PPsz-qqq),一键安装 |
| GitHub Release 打包文件(推荐) | 最新版:https://github.com/PPsz-qqq/dsh-restart-button/releases/latest/download/dsh-restart-button.tgz;指定版本:https://github.com/PPsz-qqq/dsh-restart-button/releases/download/v0.2.0/dsh-restart-button-0.2.0.tgz |
| GitHub 仓库 | github:PPsz-qqq/dsh-restart-button#v0.2.0 |
| 本地打包文件 | .tgz 的绝对路径,例如 C:\Users\<you>\.dsh\plugins\dsh-restart-button-0.2.0.tgz |
Showing the opening section of the README — the full document lives in the repository以上为 README 开头摘要,完整文档在仓库内 · View the full README on GitHub →在 GitHub 查看完整 README →
vibeinging/dsh-desktop
chokwinlee/deepseek-harness-desktop
ZSeven-W/dsh-android
robiteame/dsh-session-tree-extension
baihejiangnan/dsh-session-context-menu
chromoany/dsh-notify-me
wallpap/dsh-compact-activity
HuanLinOTO/dsh-plugin-merge-tool-calls