dsh-panel
Verified@emb-agent/dsh-panel · v0.2.0 · MIT · Web UI
emb-agent 的 DSH 面板:在有 .emb-agent/ 的项目里显示嵌入式任务看板、进度与配置页。
Install
dsh plugin add @emb-agent/dsh-panel Confirm the layer applied with dsh --profile default --dump-config — see the install guide.
Source
Published to npm without a public repository. Inspect the package contents before installing.
Creators
Readme
@emb-agent/dsh-panel
DSH 的 emb-agent 面板插件:在有 .emb-agent/ 的项目里显示嵌入式任务看板、知识库、技能商店、硬件(芯片图 / 原理图查看 / 网络分析)与配置页。
- Host 半(
lib/host.js):注册webServer路由/emb/*(status / config / action / skills / skill / hardware / schematic / schematic-file)。仅对已注册工作区路径返回数据。 - Client 半(
dist/client.js):条件注册conversation.view标签页(任务 / 知识库 / 技能 / 硬件)与settings.section(配置页)。无.emb-agent/的项目不出现任何入口。
安装
前置:已装好 DSH(dsh web 能正常运行),Node.js ≥ 20。
① 从 npm 包拿安装脚本(推荐,私有仓库也适用):
npm i -g @emb-agent/dsh-panel # 或项目级 npm i @emb-agent/dsh-panel
bash node_modules/@emb-agent/dsh-panel/scripts/install.sh # macOS / Linux
# Windows: powershell -File node_modules\@emb-agent\dsh-panel\scripts\install.ps1
② 或直接装(跳过本地脚本):
cd ~/.dsh/profiles/web
npx -y --package @deepseek-ai/dsh dsh plugin --profile web add @emb-agent/dsh-panel
③ 仓库公开时可用 GitHub 一键脚本:
# macOS / Linux
curl -fsSL https://raw.githubusercontent.com/Welkon/dsh-emb-panel/main/scripts/install.sh | bash
# Windows
irm https://raw.githubusercontent.com/Welkon/dsh-emb-panel/main/scripts/install.ps1 | iex
装完硬刷新浏览器(Cmd/Ctrl+Shift+R)即可看到面板(DSH 对 client 改动热加载;仅 host 半更新需重启 DSH)。
指定版本 / 装完自动重启(可选)
# macOS / Linux
bash node_modules/@emb-agent/dsh-panel/scripts/install.sh 0.1.2 --restart
# Windows PowerShell
& node_modules/@emb-agent/dsh-panel/scripts/install.ps1 -Version 0.1.2 -Restart
不确定可先加 --dry-run(PowerShell 用 -DryRun)预览步骤。
手动安装(逐步命令)
cd ~/.dsh/profiles/web
# ① 放行新版本(发布 <24h 时 pnpm 会拒绝;一次性)
cat >> pnpm-workspace.yaml <<'EOF'
minimumReleaseAgeExclude:
- @emb-agent/dsh-panel
EOF
# ② 安装并自动挂载
npx -y --package @deepseek-ai/dsh dsh plugin --profile web add @emb-agent/dsh-panel
回滚:dsh plugin --profile web remove @emb-agent/dsh-panel。
emb-agent init --dsh也会自动执行上述安装(一次性、每用户)。
构建
npm install --no-save --legacy-peer-deps [email protected] # 只需 esbuild(peer 由 DSH 运行时提供)
node build.mjs # 产出 dist/client.js + lib/host.js
发布
# 改 package.json version → 构建 → 提交推送 → 发布
node build.mjs
npm publish --access public
- 包名为 scoped
@emb-agent/dsh-panel,需拥有 npm@emb-agent组织权限。 prepublishOnly会自动构建。
结构
src/host/ Host 半(路由 + 状态/硬件/技能/原理图读取)
src/client/ Client 半(api / store / theme / 各标签页组件 + altium.js 原理图渲染)
scripts/ 一键安装脚本(install.sh / install.ps1)
安全说明
/emb/* 通过 workspaceRegistry.resolveByPath 校验 cwd,只读取已注册工作区的 .emb-agent/。config.yaml 与 integrations(可能含 mineru.api_key 等)会原样返回给面板,生产发布前建议按需脱敏。