@michengai/dsh-skills-manager 1.1.16 → 1.1.17

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/CHANGELOG.md CHANGED
@@ -1,5 +1,9 @@
1
1
  # Changelog
2
2
 
3
+ ## 1.1.17 - 2026-10-12
4
+
5
+ - Support DSH `0.2.1-alpha.2` while retaining all existing supported versions.
6
+
3
7
  [简体中文](CHANGELOG.zh-CN.md)
4
8
 
5
9
  ## 1.1.16 - 2026-10-12
@@ -2,6 +2,10 @@
2
2
 
3
3
  [English](CHANGELOG.md)
4
4
 
5
+ ## 1.1.17 - 2026-10-12
6
+
7
+ - 支持 DSH `0.2.1-alpha.2`,继续兼容既有已支持版本。
8
+
5
9
  ## 1.1.16 - 2026-10-12
6
10
 
7
11
  - 可以在每个技能来源里建分类,把技能归进去。分类只记在管理器里,不移动文件。每个分类可以一起启用或停用。
package/README.md CHANGED
@@ -71,7 +71,7 @@ dsh plugin --profile web add @michengai/dsh-skills-manager@latest --registry=htt
71
71
 
72
72
  Restart DSH, refresh the page, and open **Settings → Skills**. To update, select **Check for updates** or run the installation command again.
73
73
 
74
- - Plugin `1.1.16` is tested with DeepSeek Harness `0.1.2-rc.1`, `0.1.5-rc.1`, `0.1.5-rc.2`, `0.1.5-rc.3`, `0.1.7-rc.1`, `0.1.7-rc.2`, `0.2.0-rc.1`, `0.2.0-rc.2`.
74
+ - Plugin `1.1.17` is tested with DeepSeek Harness `0.1.2-rc.1`, `0.1.5-rc.1`, `0.1.5-rc.2`, `0.1.5-rc.3`, `0.1.7-rc.1`, `0.1.7-rc.2`, `0.2.0-rc.1`, `0.2.0-rc.2`, `0.2.1-alpha.2`.
75
75
 
76
76
  ## Usage
77
77
 
package/README.zh-CN.md CHANGED
@@ -71,7 +71,7 @@ dsh plugin --profile web add @michengai/dsh-skills-manager@latest --registry=htt
71
71
 
72
72
  安装后重启 DSH 并刷新页面,打开「设置 → 技能」即可使用。更新时可点击「检查更新」,或重新执行安装命令。
73
73
 
74
- - `1.1.16` 已验证兼容 DeepSeek Harness `0.1.2-rc.1`、`0.1.5-rc.1`、`0.1.5-rc.2`、`0.1.5-rc.3`、`0.1.7-rc.1`、`0.1.7-rc.2`、`0.2.0-rc.1`、`0.2.0-rc.2`。
74
+ - `1.1.17` 已验证兼容 DeepSeek Harness `0.1.2-rc.1`、`0.1.5-rc.1`、`0.1.5-rc.2`、`0.1.5-rc.3`、`0.1.7-rc.1`、`0.1.7-rc.2`、`0.2.0-rc.1`、`0.2.0-rc.2`、`0.2.1-alpha.2`。
75
75
 
76
76
  ## 使用说明
77
77
 
package/lib/index.js CHANGED
@@ -28,7 +28,7 @@ import { registerPluginUpdater } from "./plugin-updater.js";
28
28
  import { createRepositoryManager } from "./repositories.js";
29
29
  import { installationSourceKey } from "./repository-updates.js";
30
30
  const name = "skills-manager";
31
- const inject = ["webServer", "webRuntime", "skills", "tools", "sessions"];
31
+ const inject = ["webServer", "skills", "tools", "sessions"];
32
32
  const CLIENT_MARKER_HEADER = "x-dsh-skills-manager";
33
33
  const MAX_LOG_BYTES = 1 << 20;
34
34
  const MAX_UPLOAD_BODY_BYTES = 88 << 20;
@@ -282,7 +282,18 @@ function apply(ctx) {
282
282
  }), "skills-manager: plugin updater");
283
283
  const log = makeLog();
284
284
  const repositories = createRepositoryManager({ log, registeredWorkspaces: () => registeredWorkspacePaths(ctx) });
285
- const trustedHosts = Array.isArray(ctx.webRuntime.trustedHosts) ? ctx.webRuntime.trustedHosts : [];
285
+ const getTrustedHosts = () => {
286
+ try {
287
+ const rawCtx = ctx;
288
+ const root = rawCtx.root || rawCtx;
289
+ const candidate = root.webRuntime || root.webStartup;
290
+ if (candidate && typeof candidate === "object" && Array.isArray(candidate.trustedHosts)) {
291
+ return candidate.trustedHosts;
292
+ }
293
+ } catch {
294
+ }
295
+ return [];
296
+ };
286
297
  const roots = userRoots();
287
298
  const rootByKey = Object.fromEntries(roots.map((r) => [r.key, r]));
288
299
  const providerInvalidators = /* @__PURE__ */ new Set();
@@ -373,7 +384,7 @@ function apply(ctx) {
373
384
  };
374
385
  const stateWithSources = async () => attachSources(await state(projectOptions()));
375
386
  try {
376
- const hostError = validateRequestOrigin(req, trustedHosts);
387
+ const hostError = validateRequestOrigin(req, getTrustedHosts());
377
388
  if (hostError) {
378
389
  json(res, hostError.statusCode, { ok: false, code: hostError.code, error: hostError.error });
379
390
  return;
@@ -396,7 +407,7 @@ function apply(ctx) {
396
407
  json(res, 405, { ok: false, code: "error.proto.method", error: `method not allowed: ${req.method}` });
397
408
  return;
398
409
  }
399
- const requestError = validateMutationRequest(req, trustedHosts);
410
+ const requestError = validateMutationRequest(req, getTrustedHosts());
400
411
  if (requestError) {
401
412
  json(res, requestError.statusCode, { ok: false, code: requestError.code, error: requestError.error });
402
413
  return;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@michengai/dsh-skills-manager",
3
- "version": "1.1.16",
3
+ "version": "1.1.17",
4
4
  "description": "DSH Skills Manager — 在 DeepSeek Harness 中统一加载并安全管理本机 Agent Skills · Load and safely manage local Agent Skills in DSH",
5
5
  "license": "Apache-2.0",
6
6
  "repository": {
@@ -56,13 +56,13 @@
56
56
  },
57
57
  "peerDependencies": {
58
58
  "@deepseek-ai/cordis": ">=4.0.1 <5.0.0",
59
- "@deepseek-ai/dsh-client-locale": "0.1.2-rc.1 || 0.1.5-rc.1 || 0.1.5-rc.2 || 0.1.5-rc.3 || 0.1.7-rc.1 || 0.1.7-rc.2 || 0.2.0-rc.1 || 0.2.0-rc.2",
60
- "@deepseek-ai/dsh-client-ui-slots": "0.1.2-rc.1 || 0.1.5-rc.1 || 0.1.5-rc.2 || 0.1.5-rc.3 || 0.1.7-rc.1 || 0.1.7-rc.2 || 0.2.0-rc.1 || 0.2.0-rc.2",
61
- "@deepseek-ai/dsh-host-webserver": "0.1.2-rc.1 || 0.1.5-rc.1 || 0.1.5-rc.2 || 0.1.5-rc.3 || 0.1.7-rc.1 || 0.1.7-rc.2 || 0.2.0-rc.1 || 0.2.0-rc.2",
62
- "@deepseek-ai/dsh-session": "0.1.2-rc.1 || 0.1.5-rc.1 || 0.1.5-rc.2 || 0.1.5-rc.3 || 0.1.7-rc.1 || 0.1.7-rc.2 || 0.2.0-rc.1 || 0.2.0-rc.2",
63
- "@deepseek-ai/dsh-skill": "0.1.2-rc.1 || 0.1.5-rc.1 || 0.1.5-rc.2 || 0.1.5-rc.3 || 0.1.7-rc.1 || 0.1.7-rc.2 || 0.2.0-rc.1 || 0.2.0-rc.2",
64
- "@deepseek-ai/dsh-tools": "0.1.2-rc.1 || 0.1.5-rc.1 || 0.1.5-rc.2 || 0.1.5-rc.3 || 0.1.7-rc.1 || 0.1.7-rc.2 || 0.2.0-rc.1 || 0.2.0-rc.2",
65
- "@deepseek-ai/dsh-web-app": "0.1.2-rc.1 || 0.1.5-rc.1 || 0.1.5-rc.2 || 0.1.5-rc.3 || 0.1.7-rc.1 || 0.1.7-rc.2 || 0.2.0-rc.1 || 0.2.0-rc.2",
59
+ "@deepseek-ai/dsh-client-locale": "0.1.2-rc.1 || 0.1.5-rc.1 || 0.1.5-rc.2 || 0.1.5-rc.3 || 0.1.7-rc.1 || 0.1.7-rc.2 || 0.2.0-rc.1 || 0.2.0-rc.2 || 0.2.1-alpha.2",
60
+ "@deepseek-ai/dsh-client-ui-slots": "0.1.2-rc.1 || 0.1.5-rc.1 || 0.1.5-rc.2 || 0.1.5-rc.3 || 0.1.7-rc.1 || 0.1.7-rc.2 || 0.2.0-rc.1 || 0.2.0-rc.2 || 0.2.1-alpha.2",
61
+ "@deepseek-ai/dsh-host-webserver": "0.1.2-rc.1 || 0.1.5-rc.1 || 0.1.5-rc.2 || 0.1.5-rc.3 || 0.1.7-rc.1 || 0.1.7-rc.2 || 0.2.0-rc.1 || 0.2.0-rc.2 || 0.2.1-alpha.2",
62
+ "@deepseek-ai/dsh-session": "0.1.2-rc.1 || 0.1.5-rc.1 || 0.1.5-rc.2 || 0.1.5-rc.3 || 0.1.7-rc.1 || 0.1.7-rc.2 || 0.2.0-rc.1 || 0.2.0-rc.2 || 0.2.1-alpha.2",
63
+ "@deepseek-ai/dsh-skill": "0.1.2-rc.1 || 0.1.5-rc.1 || 0.1.5-rc.2 || 0.1.5-rc.3 || 0.1.7-rc.1 || 0.1.7-rc.2 || 0.2.0-rc.1 || 0.2.0-rc.2 || 0.2.1-alpha.2",
64
+ "@deepseek-ai/dsh-tools": "0.1.2-rc.1 || 0.1.5-rc.1 || 0.1.5-rc.2 || 0.1.5-rc.3 || 0.1.7-rc.1 || 0.1.7-rc.2 || 0.2.0-rc.1 || 0.2.0-rc.2 || 0.2.1-alpha.2",
65
+ "@deepseek-ai/dsh-web-app": "0.1.2-rc.1 || 0.1.5-rc.1 || 0.1.5-rc.2 || 0.1.5-rc.3 || 0.1.7-rc.1 || 0.1.7-rc.2 || 0.2.0-rc.1 || 0.2.0-rc.2 || 0.2.1-alpha.2",
66
66
  "react": "^18.2.0",
67
67
  "react-dom": "^18.2.0"
68
68
  },