@dawn0608/dsh-skill-manager 0.1.7 → 0.2.0
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/README.md +5 -29
- package/README.zh.md +5 -29
- package/lib/client.js +3 -9
- package/lib/client.js.map +2 -2
- package/lib/index.js +44 -220
- package/lib/index.js.map +4 -4
- package/package.json +3 -6
- package/lib/install-sync.js +0 -7681
- package/lib/install-sync.js.map +0 -7
- package/lib/sync-daemon.js +0 -7841
- package/lib/sync-daemon.js.map +0 -7
package/README.md
CHANGED
|
@@ -12,44 +12,20 @@ In Desktop, open **Plugins → Add plugin** and enter `@dawn0608/dsh-skill-manag
|
|
|
12
12
|
dsh plugin --profile <profile> add @dawn0608/dsh-skill-manager
|
|
13
13
|
```
|
|
14
14
|
|
|
15
|
-
Upgrade through the Harness plugin manager and restart if prompted.
|
|
16
|
-
|
|
17
|
-
### Install or upgrade optional macOS shared sync
|
|
18
|
-
|
|
19
|
-
Install or upgrade the service directly from npm.
|
|
20
|
-
|
|
21
|
-
```bash
|
|
22
|
-
npx --yes --package @dawn0608/dsh-skill-manager@0.1.7 dsh-skill-sync-install
|
|
23
|
-
```
|
|
15
|
+
Upgrade through the Harness plugin manager and restart if prompted.
|
|
24
16
|
|
|
25
17
|
## Usage and configuration
|
|
26
18
|
|
|
27
19
|
- Manage imported copies: use the switch to enable or disable a copy and the detail action to uninstall it. Bundles are stored under `$DSH_HOME/skill-manager/bundles`, activated in `$DSH_HOME/skills`.
|
|
28
20
|
- Shared skill provenance lives in `$DSH_AGENTS_HOME/skills/.provenance.json` (default `~/.agents/skills/.provenance.json`). Keys are relative paths such as `my-skill/SKILL.md`; `origin` is `self` or `third-party`. An optional credential-free HTTPS `repository` is shown for third-party skills. Unconfirmed origins appear under Third-party.
|
|
29
|
-
-
|
|
30
|
-
|
|
31
|
-
### Configure shared sync
|
|
32
|
-
|
|
33
|
-
The installer honors `DSH_HOME`, `DSH_AGENTS_HOME`, and `CLAUDE_CONFIG_DIR`, including `~/`; defaults are `~/.dsh`, `~/.agents`, and `~/.claude`. Use the same variables for Harness and the installer. It deploys the self-contained daemon to `$DSH_HOME/skill-manager/shared-sync/runtime`, configures the user LaunchAgent `local.dsh-skill-sync`, and activates synchronization after checking its identity. No Codex CLI or project hooks are required; projects are not scanned.
|
|
34
|
-
|
|
35
|
-
The service runs at login and while Harness is closed. Switches are independent: Harness stores shared-skill choices in `$DSH_HOME/skill-manager/shared-policy.json` without changing Codex or Claude settings. An unreadable shared root or temporarily invalid skill preserves existing state and links; one failing entry does not block other valid skills. The Skills page reports service failure or staleness. Clients may need refreshing or restarting to reload skills.
|
|
36
|
-
|
|
37
|
-
### Stop and recover shared sync
|
|
38
|
-
|
|
39
|
-
Uninstalling the plugin does **not** stop the independent daemon. Stop it explicitly:
|
|
40
|
-
|
|
41
|
-
```bash
|
|
42
|
-
launchctl bootout "gui/$(id -u)" "$HOME/Library/LaunchAgents/local.dsh-skill-sync.plist"
|
|
43
|
-
```
|
|
44
|
-
|
|
45
|
-
Remove that plist to prevent login startup. Stopping synchronization preserves files, links, and each client’s switches. Rerun the npm installer to start the service again.
|
|
46
|
-
|
|
47
|
-
The installer creates no routine backups. If startup fails, it rolls back only its own changes and preserves and reports concurrent edits. The daemon log is `$DSH_HOME/skill-manager/shared-sync/error.log`.
|
|
21
|
+
- Directory skills, including `~/.agents/skills`, are discovered and loaded by Harness. This plugin displays its catalog and details; only plugin-owned imported copies can be enabled, disabled, or uninstalled here.
|
|
22
|
+
- `DSH_HOME` and `DSH_AGENTS_HOME` default to `~/.dsh` and `~/.agents`; absolute paths and `~/` are supported. The plugin does not manage other applications’ skills or configuration.
|
|
48
23
|
|
|
49
24
|
## Requirements and limitations
|
|
50
25
|
|
|
51
26
|
- Requires DeepSeek Harness `>=0.2.2-rc.1 <0.3.0` and Node.js 24 or later.
|
|
52
|
-
-
|
|
27
|
+
- Supports Windows, macOS, and Linux filesystem operations. Imported copies use directory junctions on Windows and directory symlinks elsewhere; no administrator privileges or Developer Mode are required.
|
|
28
|
+
- No Python, Codex, Claude Code, or background service is required. Filesystem conflicts or files held open by another process may require resolving the conflict before retrying.
|
|
53
29
|
|
|
54
30
|
## Development
|
|
55
31
|
|
package/README.zh.md
CHANGED
|
@@ -12,44 +12,20 @@
|
|
|
12
12
|
dsh plugin --profile <profile> add @dawn0608/dsh-skill-manager
|
|
13
13
|
```
|
|
14
14
|
|
|
15
|
-
通过 Harness
|
|
16
|
-
|
|
17
|
-
### 安装或升级可选 macOS 共享同步服务
|
|
18
|
-
|
|
19
|
-
通过 npm 直接安装或升级服务。
|
|
20
|
-
|
|
21
|
-
```bash
|
|
22
|
-
npx --yes --package @dawn0608/dsh-skill-manager@0.1.7 dsh-skill-sync-install
|
|
23
|
-
```
|
|
15
|
+
通过 Harness 插件管理器升级,提示时重启。
|
|
24
16
|
|
|
25
17
|
## 使用与配置
|
|
26
18
|
|
|
27
19
|
- 管理导入副本:用开关启停,在详情中卸载。副本存放在 `$DSH_HOME/skill-manager/bundles`,通过 `$DSH_HOME/skills` 激活。
|
|
28
20
|
- 共享技能来源记录在 `$DSH_AGENTS_HOME/skills/.provenance.json`,默认 `~/.agents/skills/.provenance.json`。键为 `my-skill/SKILL.md` 等相对路径,`origin` 为 `self` 或 `third-party`。第三方可填写不含凭据的 HTTPS `repository`,用于展示原仓库链接。来源未确认的技能归入第三方。
|
|
29
|
-
-
|
|
30
|
-
|
|
31
|
-
### 配置共享同步
|
|
32
|
-
|
|
33
|
-
安装器支持 `DSH_HOME`、`DSH_AGENTS_HOME`、`CLAUDE_CONFIG_DIR` 及 `~/` 展开,默认分别为 `~/.dsh`、`~/.agents`、`~/.claude`。Harness 与安装器应使用同一组变量。安装器将自包含 daemon 部署到 `$DSH_HOME/skill-manager/shared-sync/runtime`,配置用户 LaunchAgent `local.dsh-skill-sync`,验证服务身份后启用同步。不需要 Codex CLI 或项目 hooks;服务不扫描项目目录。
|
|
34
|
-
|
|
35
|
-
服务随登录启动,Harness 关闭后仍会同步。各端开关独立:Harness 的共享技能选择保存在 `$DSH_HOME/skill-manager/shared-policy.json`,不修改 Codex 或 Claude 设置。共享根目录不可读或技能文件暂时无效时保留已有状态和链接;单个条目异常不阻塞其他有效技能。技能页提示服务异常或过期状态。客户端可能需要刷新或重启才能重新加载技能。
|
|
36
|
-
|
|
37
|
-
### 停止与恢复共享同步
|
|
38
|
-
|
|
39
|
-
卸载插件**不会**停止独立 daemon。请显式停止:
|
|
40
|
-
|
|
41
|
-
```bash
|
|
42
|
-
launchctl bootout "gui/$(id -u)" "$HOME/Library/LaunchAgents/local.dsh-skill-sync.plist"
|
|
43
|
-
```
|
|
44
|
-
|
|
45
|
-
移除该 plist 可阻止下次登录启动。停止同步保留现有文件、链接和各端开关,重新运行 npm 安装器即可恢复服务。
|
|
46
|
-
|
|
47
|
-
安装器不创建常规备份;启动失败时仅回退本次实际改动,保留并报告并发修改。daemon 日志位于 `$DSH_HOME/skill-manager/shared-sync/error.log`。
|
|
21
|
+
- 目录技能(包括 `~/.agents/skills`)由 Harness 原生发现和加载。插件展示宿主目录与详情,仅允许启停和卸载本插件拥有的导入副本。
|
|
22
|
+
- `DSH_HOME` 和 `DSH_AGENTS_HOME` 默认分别为 `~/.dsh` 和 `~/.agents`,支持绝对路径与 `~/`。插件不管理其他应用的技能或配置。
|
|
48
23
|
|
|
49
24
|
## 环境要求与限制
|
|
50
25
|
|
|
51
26
|
- 要求 DeepSeek Harness `>=0.2.2-rc.1 <0.3.0` 和 Node.js 24 或更高版本。
|
|
52
|
-
-
|
|
27
|
+
- 文件操作适配 Windows、macOS 和 Linux。导入副本在 Windows 使用目录 junction,在其他平台使用目录软链接,不需要管理员权限或开发者模式。
|
|
28
|
+
- 不需要 Python、Codex、Claude Code 或后台服务。路径冲突或其他进程占用文件时,需要排除冲突后重试。
|
|
53
29
|
|
|
54
30
|
## 开发
|
|
55
31
|
|
package/lib/client.js
CHANGED
|
@@ -40374,9 +40374,6 @@ var DICTS = {
|
|
|
40374
40374
|
saving: "Saving\u2026",
|
|
40375
40375
|
invalid: "The request is invalid.",
|
|
40376
40376
|
conflict: "The skill catalog changed. Wait for the list to refresh and try again.",
|
|
40377
|
-
sharedConflict: "A shared skill conflicts with a local entry of the same name.",
|
|
40378
|
-
sharedUnavailable: "Shared skill sync is unavailable. Check the background service and its log.",
|
|
40379
|
-
sharedStopped: "The shared skill background service has stopped or is not responding.",
|
|
40380
40377
|
"not-found": "This skill could not be found.",
|
|
40381
40378
|
unavailable: "Could not read from or connect to Harness.",
|
|
40382
40379
|
forbidden: "This page does not have permission to perform the action.",
|
|
@@ -40420,9 +40417,6 @@ var DICTS = {
|
|
|
40420
40417
|
saving: "\u6B63\u5728\u4FDD\u5B58\u2026",
|
|
40421
40418
|
invalid: "\u8BF7\u6C42\u65E0\u6548\u3002",
|
|
40422
40419
|
conflict: "\u6280\u80FD\u5217\u8868\u5DF2\u53D8\u5316\u3002\u8BF7\u7B49\u5F85\u5217\u8868\u5237\u65B0\u540E\u91CD\u8BD5\u3002",
|
|
40423
|
-
sharedConflict: "\u5171\u4EAB\u6280\u80FD\u4E0E\u540C\u540D\u672C\u5730\u6761\u76EE\u51B2\u7A81\u3002",
|
|
40424
|
-
sharedUnavailable: "\u5171\u4EAB\u6280\u80FD\u540C\u6B65\u4E0D\u53EF\u7528\uFF0C\u8BF7\u68C0\u67E5\u540E\u53F0\u670D\u52A1\u53CA\u5176\u65E5\u5FD7\u3002",
|
|
40425
|
-
sharedStopped: "\u5171\u4EAB\u6280\u80FD\u540E\u53F0\u670D\u52A1\u5DF2\u505C\u6B62\u6216\u672A\u54CD\u5E94\u3002",
|
|
40426
40420
|
"not-found": "\u627E\u4E0D\u5230\u6B64\u6280\u80FD\u3002",
|
|
40427
40421
|
unavailable: "\u65E0\u6CD5\u8FDE\u63A5 Harness \u6216\u8BFB\u53D6\u6570\u636E\u3002",
|
|
40428
40422
|
forbidden: "\u5F53\u524D\u9875\u9762\u6CA1\u6709\u6267\u884C\u6B64\u64CD\u4F5C\u7684\u6743\u9650\u3002",
|
|
@@ -40526,7 +40520,7 @@ function createCatalog(send = request) {
|
|
|
40526
40520
|
}
|
|
40527
40521
|
if (result.complete) {
|
|
40528
40522
|
hasCompleteCatalog = true;
|
|
40529
|
-
publish({ skills: result.skills, listError:
|
|
40523
|
+
publish({ skills: result.skills, listError: null });
|
|
40530
40524
|
} else if (!hasCompleteCatalog) {
|
|
40531
40525
|
publish({ skills: result.skills, listError: "incomplete" });
|
|
40532
40526
|
} else {
|
|
@@ -40750,7 +40744,7 @@ function CatalogRows({ skills, query, translate: t, busy, savingId, store, openD
|
|
|
40750
40744
|
),
|
|
40751
40745
|
descriptionId && (0, import_react7.createElement)("span", { className: "dshskill_description", id: descriptionId }, skill.description)
|
|
40752
40746
|
),
|
|
40753
|
-
typeof skill.enabled === "boolean" && (0, import_react7.createElement)(SkillToggle, { skill, busy, saving, store, translate: t, controls })
|
|
40747
|
+
skill.group === "imported" && typeof skill.enabled === "boolean" && (0, import_react7.createElement)(SkillToggle, { skill, busy, saving, store, translate: t, controls })
|
|
40754
40748
|
);
|
|
40755
40749
|
}))
|
|
40756
40750
|
);
|
|
@@ -40773,7 +40767,7 @@ function SkillDetail({ skill, titleRef, translate: t, busy, saving, back, openRe
|
|
|
40773
40767
|
return () => pending.abort();
|
|
40774
40768
|
}, [skill.id, attempt]);
|
|
40775
40769
|
const imported = skill.group === "imported";
|
|
40776
|
-
const canToggle = typeof skill.enabled === "boolean";
|
|
40770
|
+
const canToggle = skill.group === "imported" && typeof skill.enabled === "boolean";
|
|
40777
40771
|
const origin = preview?.origin ?? skill.origin;
|
|
40778
40772
|
const repository = origin === "third-party" ? preview?.repository : void 0;
|
|
40779
40773
|
const repositoryLabel = repository?.replace(/^https:\/\/(?:github\.com\/)?/, "").replace(/\/$/, "");
|