← 返回列表
C

dsh-restart

v0.1.0 · 4 天前发布

DSH 重启插件:可配置的重启方式(Node 原生 / 旧 PowerShell 适配)、重启后自动继续的提示词、可选看门狗自动拉起。

dshdeepseek-harnessrestartpluginwatchdogclient-plugin

README

dsh-restart

重启整个 DeepSeek Harness 进程的插件,用于重新加载插件与配置(profile 的 cordis 组合、settings 等)。host + client 双半,装进 profile 的 bundle 后即可用。

功能

  • 模型工具 restart_harness:让 agent 直接安排一次进程重启(可选 delayMs)。

  • /restart 斜杠命令:在 UI 里手动触发重启。

  • 配置卡片(设置 → 插件 → 插件配置 → 「DSH 重启」):可视化编辑以下设置,改动即时写入 settings.yaml

  • - legacyRestart — 旧 PowerShell/WMI/taskkill 重启方式(默认关闭,用 Node 原生方式)。
    - continuePrompt — 重启后自动继续时注入给 agent 的提示词。
    - watchdogEnabled — 崩溃/关闭时自动拉起 DSH(默认关闭,需谨慎)。
    - watchdogCooldownMs / watchdogPollMs — 看门狗冷却与轮询间隔。
  • 「立即重启」按钮:卡片内的同源重启端点。出于安全考虑,仅接受来自环回地址(127.0.0.1 / localhost)的同源 POST 请求;经反向代理/远程访问时该按钮会被拒绝(403)。
  • 安装

    1. 把包加入 profile 依赖并挂进 bundle:

    ```jsonc
    // profiles/<profile>/package.json
    {
    "dependencies": { "dsh-restart": "..." },
    "dsh": { "profile": { "bundles"

    查看完整 README →

    版本兼容矩阵

    DSH 版本状态说明
    dsh@0.1.0-rc.6 ✅ 兼容 cordis patch ✅
    dsh@0.1.0 ✅ 兼容 标准 patch ✅
    dsh@0.2.0 ⚠️ 待验证 待实测(API 可能在变)
    dsh@0.3.0+ ❓ 未知 尚未发布

    💡 兼容矩阵每周末自动跑实测,欢迎 PR 修正

    元数据

    License
    MIT
    npm
    dsh-restart
    Repo
    https://github.com/anweat/dsh-restart
    Engines
    {"node":"^22.19.0 || >=24.0.0"}
    Weekly DL
    0
    Monthly DL
    0
    Stars
    ★ 4
    Open Issues
    2
    GH License
    [object Object]
    Archived
    dsh.bundle
    {"client":{"inject":["@deepseek-ai/dsh-client-locale","@deepseek-ai/dsh-client-runtime","@deepseek-ai/dsh-client-ui-settings","@deepseek-ai/dsh-client-ui-settings-plugins"],"platform":"web"},"bundle":{"patch":"./cordis.patch.yml"}}