nevertoday/dsh-theme-plugin ↗★ 1
dsh-theme-plugin
中国传统色 DeepSeek Harness 主题包 · Chinese traditional color themes for DeepSeek Harness
安装
npx -p @deepseek-ai/dsh dsh plugin --profile web add github:nevertoday/dsh-theme-plugin说明文档
阅读完整 README ↗dsh-theme-plugin
以中国传统色为锚色的 DeepSeek Harness 主题包 —— 48 个锚色 × 亮/暗 = 96 套主题,每套写满完整 --dsw-* 令牌词表(89 个),逐套通过 WCAG AA 对比度校验(2208/2208 行,失败 0)。
安装
npx -y @deepseek-ai/dsh plugin --profile web add dsh-theme-plugin@latest
npx -y @deepseek-ai/dsh --profile web # 启动 → 打开 http://127.0.0.1:3080/
装的是 npm 上的预构建产物 —— 不用 clone,也不用构建。web profile 会在首次启动时自动创建于 ~/.dsh/profiles/web。
- 验证:
dsh --profile web --dump-config应出现theme-zhongguo行;浏览器控制台打印registered 96/96 themes。 - 更新:把上面那条
add命令再跑一次(@latest)。 - 卸载:
dsh plugin --profile web remove dsh-theme-plugin
从源码安装(开发用)
要求:Node.js 20+(package.json 的 engines;pnpm test 直跑 .ts 另需 23.6+)与 pnpm。
git clone https://github.com/nevertoday/dsh-theme-plugin
cd dsh-theme-plugin
pnpm install && pnpm build # ① 构建 lib/client.js(浏览器包)
dsh plugin --profile web add -w . # ② 挂载('.' 即当前目录)
dsh --profile web # ③ 启动 → 打开 http://127.0.0.1:3080/
- ①
pnpm install的prepare已经构建过一次,后面的pnpm build是显式的保险(用--ignore-scripts安装时它就成了必需)。需要 tsdown;备胎node scripts/build-esbuild.mjs(esbuild 已在 devDependencies 里)。仓库带一份.npmrc(auto-install-peers=false)—— 缺了它 pnpm ≥ 9 装不上:它会去装@deepseek-ai/*peer(即便都标了 optional),而dsh-client-runtime的 latest 依赖一个未发布到 npm 的包,安装会以ERR_PNPM_FETCH_404失败。 - ② 必须带
-w(profile 目录是 pnpm 工作区根)。add会把.这类相对路径锚定到执行命令的目录;以link:目录链接挂载并自动并入dsh.profile.bundles;装载器直接读工作副本里的lib/client.js—— 那个文件由步骤 ① 生成,所以不必提交(提交也可以,代价是每次安装后 553KB 产物 + 790KB sourcemap 都会显示为改动)。 - 闸门(不用起 harness):
pnpm check(2208 行对比度 + 不变量)与pnpm test(23 条行为断言,含对 的装载锁)。

