dsh-profile-panel:DSH 插件状态面板与 profile 运维控制台

前言

在 DSH 的「一切皆插件」思路下,profile、bundle、插件安装和重启通常分散在 CLI、配置与宿主能力中。维护多个 profile 时,常需要确认当前 profile 是否生效、bundle 是否待重启、多个 profile 的插件版本是否一致,以及一次安装是否需要回滚。

dsh-profile-panel 是一个 DSH 插件,把这类操作集中到 settings 面板里的 profile-panel 分区。

这是什么

dsh-profile-panel 是 lingxin-maz 维护的 DSH 插件状态面板 / profile 运维控制台。仓库名为 lingxin-maz/dsh-profilespanel,npm 包名为 dsh-profile-panel,许可证为 MIT。

它用于观察、诊断、变更管理与 Agent 化,覆盖:

  • 当前 profile、bundle 状态与待重启检测(SSE)
  • 一键重启
  • 多 profile 同步安装(web+desktop 双端模式)
  • 供应链版本预览(minimumReleaseAge 发布年龄预警)
  • 安装前快照、失败自动回滚、手动撤销
  • 更新检测与跨 profile 版本对齐
  • 健康检查(缺失包/peer 缺口/孤儿 bundle/层栈重复)
  • 两 profile 并排 diff
  • 启动报告
  • 审计日志(本地 JSONL)
  • Agent 工具:profile_status / profile_updates / profile_sync_install / profile_restart
  • 市场搜索与 github:owner/repo 直装
  • 热加载(宿主支持时)

它安装到指定 DSH profile,而不是作为独立应用运行。插件以当前 dsh 进程权限运行,安装前建议检查源码与许可证。

社区目录页是独立站点,与 DeepSeek / 幻方无官方从属关系,不应理解为官方应用商店。

核心功能

观察与诊断

下面先介绍用于查看状态的几类能力。

  • 当前 profile、bundle 状态与待重启检测(SSE)。
  • 更新检测与跨 profile 版本对齐。
  • 健康检查:缺失包、peer 缺口、孤儿 bundle、层栈重复。
  • 两 profile 并排 diff。
  • 启动报告。
  • 审计日志:本地 JSONL。

变更管理

下面介绍会实际改变插件或 profile 状态的操作。

  • 一键重启。
  • 多 profile 同步安装(web+desktop 双端模式)。
  • 供应链版本预览:minimumReleaseAge 发布年龄预警。
  • 安装前快照、失败自动回滚、手动撤销。
  • 热加载(宿主支持时)。

Agent 与市场对接

下面介绍面向模型调用与市场入口的能力。

  • Agent 工具:profile_status / profile_updates / profile_sync_install / profile_restart
  • 市场搜索与 github:owner/repo 直装。

安装与启用

运行环境要求 node >=18peerDependencies 包含:

{
  "@deepseek-ai/cordis": "^4.0.1",
  "@deepseek-ai/schemastery": "^3.18.1"
}

通过 registry 安装:

dsh plugin --profile <name> add dsh-profile-panel

如需固定版本:

dsh plugin --profile <name> add dsh-profile-panel@1.0.0

GitHub 直装:

dsh plugin --profile <name> add github:lingxin-maz/dsh-profilespanel

本地路径:

dsh plugin --profile desktop add ../dsh-profilespanel

安装后打开:

设置 → Profile / 插件(settings 面板的 profile-panel 分区)

验证接口:

GET http://127.0.0.1:<port>/api/profile-panel/status

返回 200 即安装成功。

典型用法

cordis.yml 中可配置:

profile-panel:
  profile: web
  allowRestart: true
  pollIntervalMs: 5000
  minimumReleaseAgeDays: 7

配置项含义:

  • profile:显式指定 profile。
  • allowRestart:是否允许一键重启。
  • pollIntervalMs:变更检测轮询间隔。
  • minimumReleaseAgeDays:供应链版本预览的发布年龄阈值。

市场页可通过事件或深链把包名送进下载模块:

dsh-profile-panel:install-target
#dshpp-install=<target>

适用场景与注意

适合需要维护多个 DSH profile、执行插件安装/更新/重启、查看 bundle 状态,或把 profile 运维操作交给 Agent 工具的场景。

使用前注意:

  • 插件以当前 dsh 进程权限运行,安装前应检查源码与 MIT 许可证。
  • 变更类接口仅接受同源环回 POST,并拒绝代理转发头。
  • 安装目标仅接受 registry 包名/版本 spec 与严格形态 github:owner/repo[#path:/sub],拒绝本地路径、git URL、http 源与命令注入。
  • GitHub 直装跟随仓库 HEAD,无版本号语义。
  • 多 profile 安装默认不自动回滚,可勾选 rollbackundo 恢复 manifest 后需 pnpm install
  • 热加载在宿主不支持时降级为重启提示。
  • updates / install-preview 依赖 registry 可用性,离线时降级为 warning。
  • 桌面端检测为启发式;dual 目标另一端缺失时降级为单端 + warning。
  • 市场搜索在线目录不可达时回退本机 dshmarket 快照,可能滞后于在线目录。
  • 审计日志为本地 JSONL,不含对话内容;零遥测。

链接

  • GitHub:https://github.com/lingxin-maz/dsh-profilespanel
  • 目录页:https://www.skillhub.cn/plugins/lingxin-maz/dsh-profilespanel
羽毛球分组比赛记分
小程序二维码

欢迎使用《羽毛球分组比赛记分》微信小程序

Xiaoye