Merge pull request 'feat/marketplace-first-skill-ops-and-skillset-update' (#3) from feat/marketplace-first-skill-ops-and-skillset-update into develop

Reviewed-on: #3
This commit was merged in pull request #3.
This commit is contained in:
2026-08-21 08:26:21 +00:00
9 changed files with 46 additions and 23 deletions
+1 -1
View File
@@ -1,6 +1,6 @@
{
"name": "jsc-meta",
"version": "0.0.1",
"version": "0.0.2",
"description": "技能組自我管理:新建/更新/刪除技能與技能準則",
"skills": "./skills",
"author": {
+1 -1
View File
@@ -1,6 +1,6 @@
{
"name": "jsc-meta",
"version": "0.0.1",
"version": "0.0.2",
"description": "技能組自我管理:新建/更新/刪除技能與技能準則",
"skills": "./skills"
}
+6 -2
View File
@@ -28,11 +28,15 @@ Marketplace 統一為 `jsc`(https://gitea.jsc.idv.tw/plugins/jsc.git),安
### `skill-update`
更新技能:列出全部技能 → 使用者選擇 → 決策樹問更新細節 → 更新後依審核檢查清單逐項檢查,不符就回到詢問 → PR。
更新技能:先查 Gitea 正本 marketplace 取得 domain 清單並補 clone 缺少的存取庫,列出全部技能 → 使用者選擇 → 決策樹問更新細節 → 更新後依審核檢查清單逐項檢查,不符就回到詢問 → PR。
### `skill-delete`
刪除技能:列出全部技能 → 使用者選擇 → sub agent 盤點關聯檔案 → 逐檔判斷是否需修正以維持功能(需要就決策樹問修正細節並依準則檢查)→ 刪除 → PR。
刪除技能:先查 Gitea 正本 marketplace 取得 domain 清單並補 clone 缺少的存取庫,列出全部技能 → 使用者選擇 → sub agent 盤點關聯檔案 → 逐檔判斷是否需修正以維持功能(需要就決策樹問修正細節並依準則檢查)→ 刪除 → sub agent 實地檢查各 CLI 的技能與 hook 保存位置,確認沒有殘留 → PR。
### `skillset-update`
批次更新——把一份變更需求套用到整個技能組的多個技能/domain,逐 repo 開 PR;單一技能改用 skill-update。
### `ste100-sync`
+1 -1
View File
@@ -1,6 +1,6 @@
{
"name": "jsc-meta",
"version": "0.0.1",
"version": "0.0.2",
"description": "技能組自我管理:新建/更新/刪除技能與技能準則",
"skills": "./skills/"
}
+2 -2
View File
@@ -35,7 +35,7 @@
## 技能設計
1. 每個技能必須有單一明確目標,不可與既有技能重複;能複用就複用(呼叫其他技能或工具)。
2. 需要操作 gitea 且輸入輸出明確的技能,一律透過 `jsc-gitea/tools/gitea.sh`(curl + `GITEA_TOKEN`)或 `tea` CLI,不可自行拼 API 呼叫。
2. 需要操作 gitea 且輸入輸出明確的技能,一律透過 `jsc-gitea/tools/gitea.sh`(curl + `GITEA_TOKEN`)或 `tea` CLI,不可自行拼 API 呼叫。gitea.sh 在 token 未設定或收到 401/403 時,會自動改用 tea 的登入金鑰重試一次。
3. 需要問使用者的技能,一律透過 `jsc-ask:ask` 的決策樹規則:選項式提問、每個選項標明影響範圍、問到沒有疑慮為止、已有紀錄的答案不再問。
## 語言
@@ -58,7 +58,7 @@
| 變數 | 用途 | 未設定時 |
| --- | --- | --- |
| `GITEA_HOST` | Gitea 站台(例:`https://gitea.jsc.idv.tw`) | 詢問使用者 |
| `GITEA_TOKEN` | Gitea API token | 詢問使用者 |
| `GITEA_TOKEN` | Gitea API token | 改用 tea 登入金鑰(`tea login list`);tea 也沒有才詢問使用者 |
| `JSC_WIKI_REPO_{TYPE}` | 各類型 wiki 頁所在的 `{owner}/{repo}`;TYPE = `QUESTION` / `PLAN` / `ANALYZE` / `MAINTAIN` / `REPO` / `LOG` | 退回 `JSC_WIKI_REPO` |
| `JSC_WIKI_REPO` | 未逐類設定時的共用 wiki `{owner}/{repo}` | 詢問使用者 |
| `JSC_HOME` | Hook 資料目錄 | 預設 `~/.jsc` |
+10 -8
View File
@@ -1,6 +1,6 @@
---
name: skill-delete
description: Remove a skill from the jsc skill set safely. List skills, let the user pick, inventory every file referencing the skill via a sub agent, fix each affected file through decision-tree questions until guideline checks pass, then delete the skill and open a PR via jsc-git pr. Use only for removal; not for renaming (use skill-update).
description: Remove a skill from the jsc skill set safely. List skills starting from the Gitea canonical marketplace (cloning any missing domain repo), let the user pick, inventory every file referencing the skill via a sub agent, fix each affected file through decision-tree questions until guideline checks pass, then delete the skill, deep-verify each installed CLI's on-disk skill and hook storage is clean, and open a PR via jsc-git pr. Use only for removal; not for renaming (use skill-update).
---
# skill-delete — delete a skill
@@ -9,14 +9,16 @@ Single source of guidelines: [`../../references/guidelines.md`](../../references
## Flow
1. List every skill in the skill set: scan `jsc-*/skills/*/SKILL.md`.
2. Let the user pick the skill to delete. Options state the impact scope: which skills reference it, and that its command stops working after deletion.
3. Inventory every file related to the skill — this step MUST run as a sub agent:
1. Query Gitea for the canonical skill set first: run `jsc-gitea/tools/gitea.sh api GET /repos/plugins/jsc/raw/.claude-plugin/marketplace.json` to get the authoritative domain list, then scan local `jsc-*/skills/*/SKILL.md` and present a "domain / name / description" list covering every domain in the marketplace. Completion condition: the list covers all marketplace domains.
2. For any marketplace domain whose repo is missing from the working directory, clone it first (`gitea.sh clone-url plugins/{domain}`), then rescan. Completion condition: every domain repo exists locally.
3. Let the user pick the skill to delete. Options state the impact scope: which skills reference it, and that its command stops working after deletion.
4. Inventory every file related to the skill — this step MUST run as a sub agent:
- `grep -r` for the skill name and `/jsc-{domain}:{name}` across all jsc-* repositories
- References in other SKILL.md files, the domain README's 「Skills 目錄」 section, the two marketplace.json files in `plugins/jsc` plus their synced copies in every domain repo, `tools/`, and the `jsc-hooks` wiring
4. For each affected file:
5. For each affected file:
1. Decide whether the file needs a fix to keep its current behavior after the deletion. If no fix is needed, **skip the rest of this loop**.
2. Ask for fix details via the `jsc-ask:ask` decision tree (call a replacement skill? inline the flow? drop the feature too?). Every option states its impact scope.
3. After fixing, check the guidelines.md audit checklist. On failure, return to step 4.2.
5. Delete the skill directory `skills/{name}/`, then sync the domain README and bump the version in all three manifests.
6. Call `jsc-git:pr` to open a Push Request.
3. After fixing, check the guidelines.md audit checklist. On failure, return to step 5.2.
6. Delete the skill directory `skills/{name}/`, then sync the domain README and bump the version in all three manifests.
7. Deep-delete verification — this step MUST run as a sub agent: after deleting via each CLI's native plugin commands, physically inspect every installed CLI's on-disk skill and hook storage. Detect CLIs via `jsc-cli/tools/detect-clis.sh`; check Claude's `~/.claude/plugins/cache/` and hook entries in settings, plus the equivalent locations for codex / copilot / antigravity / kiro. Confirm no file or hook wiring for the deleted skill remains. Completion condition: every location checked and clean; remove any leftover by hand and recheck.
8. Call `jsc-git:pr` to open a Push Request.
+1 -1
View File
@@ -14,7 +14,7 @@ Single source of guidelines: [`../../references/guidelines.md`](../../references
- Trigger (when to use, when not to, trigger keywords)
- Input and output (can a standard input/output flow move down to `tools/`; does it need Gitea operations — if so, make the skill use `jsc-gitea/tools/gitea.sh` + token)
- Owning domain (list the existing `jsc-*` domains to choose from)
2. If the domain does not exist:
2. If the domain does not exist (if the repository exists on Gitea but not in the working directory, clone it and skip to step 3):
1. Propose one short English word for the new domain (a single word preferred) and confirm it with the user.
2. Ask the user to create the repository `plugins/{domain}`. Clone it, then build the content following the structure of `https://gitea.jsc.idv.tw/plugins/template`: three plugin manifests (plugin name `jsc-{domain}`, version starting at `0.0.1`), `skills/`, README.md, AGENTS.md.
3. Add the plugin entry (URL source pointing at the new repository) to `.claude-plugin/marketplace.json` and `.agents/plugins/marketplace.json` in `plugins/jsc` (the canonical copy), then sync the two updated files to every domain repository, including the new one. Every repo carries the same marketplace files, so any repo works as the registration entry point. The sync MUST run as a sub agent.
+8 -7
View File
@@ -1,6 +1,6 @@
---
name: skill-update
description: Update an existing skill in the jsc skill set. List all skills, let the user pick one, ask update details via decision tree, apply the change, re-check against the guidelines checklist until it passes, then open a PR via jsc-git pr. Use for modifying a skill; not for creating (skill-new) or removing (skill-delete).
description: Update an existing skill in the jsc skill set. List all skills starting from the Gitea canonical marketplace (plugins/jsc marketplace.json), cloning any missing domain repo, then let the user pick one, ask update details via decision tree, apply the change, re-check against the guidelines checklist until it passes, then open a PR via jsc-git pr. Use for modifying a skill; not for creating (skill-new) or removing (skill-delete).
---
# skill-update — update a skill
@@ -9,9 +9,10 @@ Single source of guidelines: [`../../references/guidelines.md`](../../references
## Flow
1. List every skill in the skill set: scan `jsc-*/skills/*/SKILL.md` and present a "domain / name / description" list.
2. Let the user pick the skill to update.
3. Ask for update details via the `jsc-ask:ask` decision tree (change the goal? the trigger? the flow? move rules down to a hook or a tool?). Every option states its impact scope (example: renaming breaks the existing invocation command).
4. Update the skill — this step MUST run as a sub agent: modify SKILL.md and related files, sync the domain README's 「Skills 目錄」 section, and bump the version in all three manifests.
5. Check every item of the guidelines.md audit checklist. On any failure, **return to step 3**: ask again and fix, until all items pass.
6. Call `jsc-git:pr` to open a Push Request.
1. Query Gitea for the canonical skill set first: run `jsc-gitea/tools/gitea.sh api GET /repos/plugins/jsc/raw/.claude-plugin/marketplace.json` to get the authoritative domain list, then scan local `jsc-*/skills/*/SKILL.md` and present a "domain / name / description" list covering every domain in the marketplace. Completion condition: the list covers all marketplace domains.
2. For any marketplace domain whose repo is missing from the working directory, clone it first (`gitea.sh clone-url plugins/{domain}`), then rescan. Completion condition: every domain repo exists locally.
3. Let the user pick the skill to update.
4. Ask for update details via the `jsc-ask:ask` decision tree (change the goal? the trigger? the flow? move rules down to a hook or a tool?). Every option states its impact scope (example: renaming breaks the existing invocation command).
5. Update the skill — this step MUST run as a sub agent: modify SKILL.md and related files, sync the domain README's 「Skills 目錄」 section, and bump the version in all three manifests.
6. Check every item of the guidelines.md audit checklist. On any failure, **return to step 4**: ask again and fix, until all items pass.
7. Call `jsc-git:pr` to open a Push Request.
+16
View File
@@ -0,0 +1,16 @@
---
name: skillset-update
description: Apply one change request across the whole jsc skill set — multiple skills in multiple domains in one pass. Ask the change details via decision tree, sync every domain repo from the Gitea canonical marketplace, apply the change per affected domain via sub agents, re-check against the guidelines checklist until it passes, then open a PR per affected repo via jsc-git pr. Use when a change spans multiple skills or domains; not for a single skill (use skill-update).
---
# skillset-update — apply one change across the skill set
Single source of guidelines: [`../../references/guidelines.md`](../../references/guidelines.md).
## Flow
1. Ask for the change details via the `jsc-ask:ask` decision tree: what rule or behavior changes, which skills and which domains are affected. Every option states its impact scope (example: changing a shared flow step touches every skill that calls it). Completion condition: the affected-skill list is agreed with the user.
2. Query the Gitea canonical marketplace for the authoritative domain list: run `jsc-gitea/tools/gitea.sh api GET /repos/plugins/jsc/raw/.claude-plugin/marketplace.json`. Clone any domain repo missing from the working directory (`gitea.sh clone-url plugins/{domain}`) and pull the rest. Completion condition: every domain repo exists locally and is current.
3. Apply the change to every affected skill — this step MUST run as a sub agent, one sub agent per affected domain repo: modify SKILL.md and related files and tools, sync that domain README's 「Skills 目錄」 section, and bump the version in all three manifests. Completion condition: every affected domain repo carries the change, the README sync, and the manifest bump.
4. Check every item of the guidelines.md audit checklist for each touched skill. On any failure, **return to step 1**: ask again and fix, until all items pass.
5. Call `jsc-git:pr` once per affected domain repo to open a Push Request. Completion condition: every affected repo has a PR URL.