Author SHA1 Message Date
jiantw83andClaude Opus 5 41762db1b8 chore(plugin 版本): 三份 manifest 升版至 0.0.4
Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
2026-08-25 11:58:11 +08:00
jiantw83andClaude Opus 5 e5584bee80 fix(pr): base 分支優先採用呼叫端指定值,不再自行退回 develop
Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
2026-08-25 11:58:11 +08:00
admin 99e2e09175 Merge pull request '發佈 jsc-git 0.0.3:marketplace 正本移至 plugins/meta' (#6) from develop into master
Reviewed-on: #6
Reviewed-by: 系統管理員 <1+admin@noreply.localhost>
2026-08-24 10:18:13 +00:00
admin 9f5657c108 Merge pull request 'chore(marketplace 正本): 正本移至 plugins/meta(升版 0.0.3)' (#5) from chore/marketplace-canon-to-meta into develop
Reviewed-on: #5
Reviewed-by: 系統管理員 <1+admin@noreply.localhost>
2026-08-24 10:06:27 +00:00
jiantw83andClaude Opus 5 80e0b495c6 chore(plugin 版本): 三份 manifest 升版至 0.0.3
Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
2026-08-24 18:00:35 +08:00
jiantw83andClaude Opus 5 13c9684246 docs(README): 安裝入口改為 plugins/meta 並補上遷移說明
Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
2026-08-24 18:00:35 +08:00
admin 2319ef6bbb Merge pull request '發佈 jsc-git 0.0.2:pr 技能新增 slugify.sh 分支命名工具與稽核修正' (#4) from develop into master
Reviewed-on: #4
Reviewed-by: 系統管理員 <1+admin@noreply.localhost>
2026-08-24 08:26:42 +00:00
admin 9ce424e28f Merge pull request 'fix/sync-marketplace-metadata-and-pr-skill-audit-fixes' (#3) from fix/sync-marketplace-metadata-and-pr-skill-audit-fixes into develop
Reviewed-on: #3
Reviewed-by: 系統管理員 <1+admin@noreply.localhost>
2026-08-24 07:59:34 +00:00
jiantw83andClaude Sonnet 5 49e4f3e35b feat(pr): 新增 slugify.sh 分支命名工具並修正 pr 技能稽核項目
What: 新增 tools/slugify.sh 腳本,將分支類型與短語轉成 ASCII slug;修改 skills/pr/SKILL.md,把原本內嵌在文字說明中的 slugify 規則改為呼叫 tools/slugify.sh,並把 Rules 段落中「分支標題摘要」與「描述撰寫」都標記為必須交由 sub agent 執行(原本只有描述撰寫一項),同時把一個非英文範例字串替換成全英文範例;plugin.json、.claude-plugin/plugin.json、.codex-plugin/plugin.json 三份 manifest 版本號由 0.0.1 升到 0.0.2。
Why: 因應 jsc-meta:skill-check 稽核結果,pr 技能有兩項不合規:決定性的分支名稱 slugify 流程應該工具化而非寫成文字規則,避免各 agent 各自理解出現落差;另外,需要判斷力的步驟(分支標題摘要、描述撰寫)標記不一致,只標了描述撰寫一項會讓分支標題摘要漏掉必要的 sub agent 隔離;範例字串混雜非英文也不符合技能文件全英文的要求。
How: 新增可執行的 tools/slugify.sh(小寫化、非 a-z0-9 字元轉連字號、合併連續連字號、去除頭尾連字號),並在 SKILL.md 步驟 3.2 改為呼叫此腳本;同步更新 Rules 第 3 項,把「分支標題摘要」與「描述撰寫」都列為必須交由 sub agent 執行;把範例改成全英文;三份 plugin manifest 版本號同步升版以反映此次修改。
Who: 影響 jsc-git 的 pr 技能與其新增的 slugify.sh 工具,屬 pr 流程分支命名與稽核合規的功能性變更。

Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
2026-08-24 14:47:31 +08:00
jiantw83andClaude Sonnet 5 be70cd58ee fix(marketplace): 補齊 marketplace.json 缺漏的 description 與 owner 欄位
What: 在 .agents/plugins/marketplace.json 加入頂層 owner 欄位(name: JSC)與整體說明,並為 jsc-ask、jsc-cli、jsc-git、jsc-gitea、jsc-hooks、jsc-log、jsc-meta、jsc-pkg、jsc-review、jsc-sdlc 十個 plugin 逐一補上 description;同時把 .claude-plugin/marketplace.json 裡 jsc-meta 的說明標點從斜線改成頓號,與正本用字一致。
Why: 兩份 marketplace.json 是 plugins/jsc 正本的副本,先前副本落後於正本,缺少 description 與 owner 欄位會讓各 CLI 的 marketplace 清單顯示不完整,也造成多份副本之間內容不一致。
How: 逐一比對 plugins/jsc 正本內容,把缺漏欄位補齊到 .agents/plugins/marketplace.json,並修正 .claude-plugin/marketplace.json 的用字差異,使兩份副本與正本同步。
Who: 影響 jsc-git 倉庫內所有 marketplace.json 副本,屬全倉庫層級的基礎設施修正,非單一技能功能。

Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
2026-08-24 14:47:12 +08:00
admin 06471548d9 Merge pull request 'feat(git): 匯入 jsc-git 技能組並統一 marketplace 為 jsc' (#2) from develop into master
Reviewed-on: #2
Reviewed-by: 系統管理員 <1+admin@noreply.localhost>
2026-08-21 06:42:26 +00:00
jiantw83andClaude Fable 5 121cc93c38 chore(git): 加入統一 jsc marketplace 副本(與正本一致,任一 repo 可作註冊入口)
Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
2026-08-21 14:37:45 +08:00
jiantw83andClaude Fable 5 89f30f9c5e style(git): 中文並列改頓號
Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
2026-08-21 14:29:45 +08:00
jiantw83andClaude Fable 5 226dcc4a6b docs(git): translate SKILL.md into English per guidelines
Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
2026-08-21 14:29:45 +08:00
jiantw83andClaude Fable 5 a308aed68f style(git): 依 STE100 擬人台灣感規則改寫語感
Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
2026-08-21 14:15:55 +08:00
jiantw83andClaude Fable 5 e8d1c28b5a docs(git): AGENTS 語言規則改指向 jsc-meta 的 references/ste100.md
Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
2026-08-21 14:13:27 +08:00
10 changed files with 258 additions and 58 deletions
+89
View File
@@ -0,0 +1,89 @@
{
"name": "jsc",
"description": "jsc 跨 AI 助理技能組的統一 marketplace(claude / codex / copilot / antigravity / kiro)。",
"owner": {
"name": "JSC"
},
"plugins": [
{
"name": "jsc-ask",
"source": {
"source": "url",
"url": "https://gitea.jsc.idv.tw/plugins/ask.git"
},
"description": "決策樹問詢與問詢紀錄(QUESTION_* wiki 頁)"
},
{
"name": "jsc-cli",
"source": {
"source": "url",
"url": "https://gitea.jsc.idv.tw/plugins/cli.git"
},
"description": "CLI 偵測、模型能力標籤與技能庫批次部署"
},
{
"name": "jsc-git",
"source": {
"source": "url",
"url": "https://gitea.jsc.idv.tw/plugins/git.git"
},
"description": "Commit 分組認可與 Push Request 建立"
},
{
"name": "jsc-gitea",
"source": {
"source": "url",
"url": "https://gitea.jsc.idv.tw/plugins/gitea.git"
},
"description": "Gitea API 工具、Wiki 讀寫與存取庫批次同步"
},
{
"name": "jsc-hooks",
"source": {
"source": "url",
"url": "https://gitea.jsc.idv.tw/plugins/hooks.git"
},
"description": "跨 CLI hooks:STE100 語言強制、工時計時、技能用量記錄"
},
{
"name": "jsc-log",
"source": {
"source": "url",
"url": "https://gitea.jsc.idv.tw/plugins/log.git"
},
"description": "工作日誌(LOG_* wiki 頁)與技能使用統計"
},
{
"name": "jsc-meta",
"source": {
"source": "url",
"url": "https://gitea.jsc.idv.tw/plugins/meta.git"
},
"description": "技能組自我管理:新建、更新、刪除技能與技能準則"
},
{
"name": "jsc-pkg",
"source": {
"source": "url",
"url": "https://gitea.jsc.idv.tw/plugins/pkg.git"
},
"description": "套件批次更新(nodejs/python/dotnet),失敗還原"
},
{
"name": "jsc-review",
"source": {
"source": "url",
"url": "https://gitea.jsc.idv.tw/plugins/review.git"
},
"description": "程式碼審查:Refactoring 壞味道六組 + 註解規範 + 淺模組"
},
{
"name": "jsc-sdlc",
"source": {
"source": "url",
"url": "https://gitea.jsc.idv.tw/plugins/sdlc.git"
},
"description": "開發生命週期:規劃/分析/實作/維護(wiki 追蹤)"
}
]
}
+89
View File
@@ -0,0 +1,89 @@
{
"name": "jsc",
"description": "jsc 跨 AI 助理技能組的統一 marketplace(claude / codex / copilot / antigravity / kiro)。",
"owner": {
"name": "JSC"
},
"plugins": [
{
"name": "jsc-ask",
"source": {
"source": "url",
"url": "https://gitea.jsc.idv.tw/plugins/ask.git"
},
"description": "決策樹問詢與問詢紀錄(QUESTION_* wiki 頁)"
},
{
"name": "jsc-cli",
"source": {
"source": "url",
"url": "https://gitea.jsc.idv.tw/plugins/cli.git"
},
"description": "CLI 偵測、模型能力標籤與技能庫批次部署"
},
{
"name": "jsc-git",
"source": {
"source": "url",
"url": "https://gitea.jsc.idv.tw/plugins/git.git"
},
"description": "Commit 分組認可與 Push Request 建立"
},
{
"name": "jsc-gitea",
"source": {
"source": "url",
"url": "https://gitea.jsc.idv.tw/plugins/gitea.git"
},
"description": "Gitea API 工具、Wiki 讀寫與存取庫批次同步"
},
{
"name": "jsc-hooks",
"source": {
"source": "url",
"url": "https://gitea.jsc.idv.tw/plugins/hooks.git"
},
"description": "跨 CLI hooks:STE100 語言強制、工時計時、技能用量記錄"
},
{
"name": "jsc-log",
"source": {
"source": "url",
"url": "https://gitea.jsc.idv.tw/plugins/log.git"
},
"description": "工作日誌(LOG_* wiki 頁)與技能使用統計"
},
{
"name": "jsc-meta",
"source": {
"source": "url",
"url": "https://gitea.jsc.idv.tw/plugins/meta.git"
},
"description": "技能組自我管理:新建、更新、刪除技能與技能準則"
},
{
"name": "jsc-pkg",
"source": {
"source": "url",
"url": "https://gitea.jsc.idv.tw/plugins/pkg.git"
},
"description": "套件批次更新(nodejs/python/dotnet),失敗還原"
},
{
"name": "jsc-review",
"source": {
"source": "url",
"url": "https://gitea.jsc.idv.tw/plugins/review.git"
},
"description": "程式碼審查:Refactoring 壞味道六組 + 註解規範 + 淺模組"
},
{
"name": "jsc-sdlc",
"source": {
"source": "url",
"url": "https://gitea.jsc.idv.tw/plugins/sdlc.git"
},
"description": "開發生命週期:規劃/分析/實作/維護(wiki 追蹤)"
}
]
}
+1 -1
View File
@@ -1,6 +1,6 @@
{ {
"name": "jsc-git", "name": "jsc-git",
"version": "0.0.1", "version": "0.0.4",
"description": "Commit 分組認可與 Push Request 建立", "description": "Commit 分組認可與 Push Request 建立",
"skills": "./skills", "skills": "./skills",
"author": { "author": {
+1 -1
View File
@@ -1,6 +1,6 @@
{ {
"name": "jsc-git", "name": "jsc-git",
"version": "0.0.1", "version": "0.0.4",
"description": "Commit 分組認可與 Push Request 建立", "description": "Commit 分組認可與 Push Request 建立",
"skills": "./skills" "skills": "./skills"
} }
+1 -1
View File
@@ -4,7 +4,7 @@
## 規則 ## 規則
1. 所有交談與輸出內容基於 STE100 使用繁體中文:短句、一句一指令、主動語態、術語一致、UTF-8 無亂碼。 1. 所有交談與輸出內容使用 STE100 繁體中文,帶擬人台灣感:短句、一句一指令、台灣用語、全形標點、去 AI 味、直接講重點。完整規則的唯一來源:`plugins/meta` 的 `references/ste100.md`。
2. 技能位於 `skills/{name}/SKILL.md`;處理任務前先比對需求與各技能的 `description`,相符就載入並依其步驟執行。 2. 技能位於 `skills/{name}/SKILL.md`;處理任務前先比對需求與各技能的 `description`,相符就載入並依其步驟執行。
3. 技能準則的唯一來源:`plugins/meta` 存取庫的 `references/guidelines.md`。 3. 技能準則的唯一來源:`plugins/meta` 存取庫的 `references/guidelines.md`。
4. 所有 hook 只放在 `jsc-hooks`;gitea 操作一律經由 `jsc-gitea` 的 `tools/gitea.sh`;問使用者一律依 `jsc-ask:ask` 的決策樹規則。 4. 所有 hook 只放在 `jsc-hooks`;gitea 操作一律經由 `jsc-gitea` 的 `tools/gitea.sh`;問使用者一律依 `jsc-ask:ask` 的決策樹規則。
+10 -8
View File
@@ -1,21 +1,23 @@
# jsc-git — Commit 與 Push Request # jsc-git — Commit 與 Push Request
jsc 技能組的 git domain:把檔案變更依「類型 + 需求/功能」分組認可,並建立符合範本的 Push Request。 jsc 技能組的 git domain:把檔案變更依同類型與同需求或功能分組認可,並建立符合範本的 Push Request。
## 安裝 / 更新 / 移除 ## 安裝、更新、移除
Marketplace 統一為 `jsc`(https://gitea.jsc.idv.tw/plugins/jsc.git),安裝 token 為 `jsc-git@jsc`。每個指令一行: Marketplace 統一為 `jsc`(https://gitea.jsc.idv.tw/plugins/meta.git),安裝 token 為 `jsc-git@jsc`。每個指令一行:
| CLI | 安裝 | 更新 | 移除 | | CLI | 安裝 | 更新 | 移除 |
| --- | --- | --- | --- | | --- | --- | --- | --- |
| claude | `claude plugin marketplace add https://gitea.jsc.idv.tw/plugins/jsc.git && claude plugin install jsc-git@jsc` | `claude plugin marketplace update jsc && claude plugin update jsc-git@jsc` | `claude plugin uninstall jsc-git@jsc` | | claude | `claude plugin marketplace add https://gitea.jsc.idv.tw/plugins/meta.git && claude plugin install jsc-git@jsc` | `claude plugin marketplace update jsc && claude plugin update jsc-git@jsc` | `claude plugin uninstall jsc-git@jsc` |
| codex | `codex plugin marketplace add https://gitea.jsc.idv.tw/plugins/jsc.git && codex plugin add jsc-git@jsc` | `codex plugin marketplace upgrade jsc` | `codex plugin remove jsc-git@jsc` | | codex | `codex plugin marketplace add https://gitea.jsc.idv.tw/plugins/meta.git && codex plugin add jsc-git@jsc` | `codex plugin marketplace upgrade jsc` | `codex plugin remove jsc-git@jsc` |
| copilot | `copilot plugin marketplace add https://gitea.jsc.idv.tw/plugins/jsc.git && copilot plugin install jsc-git@jsc` | `copilot plugin marketplace update jsc && copilot plugin update jsc-git@jsc` | `copilot plugin uninstall jsc-git@jsc` | | copilot | `copilot plugin marketplace add https://gitea.jsc.idv.tw/plugins/meta.git && copilot plugin install jsc-git@jsc` | `copilot plugin marketplace update jsc && copilot plugin update jsc-git@jsc` | `copilot plugin uninstall jsc-git@jsc` |
| antigravity | `git clone https://gitea.jsc.idv.tw/plugins/git.git ~/plugins/git && agy plugin install ~/plugins/git` | `git -C ~/plugins/git pull && agy plugin uninstall jsc-git && agy plugin install ~/plugins/git` | `agy plugin uninstall jsc-git` | | antigravity | `git clone https://gitea.jsc.idv.tw/plugins/git.git ~/plugins/git && agy plugin install ~/plugins/git` | `git -C ~/plugins/git pull && agy plugin uninstall jsc-git && agy plugin install ~/plugins/git` | `agy plugin uninstall jsc-git` |
| kiro | `kiro-cli plugin marketplace add https://gitea.jsc.idv.tw/plugins/jsc.git && kiro-cli plugin install jsc-git@jsc` | `kiro-cli plugin marketplace update jsc && kiro-cli plugin update jsc-git@jsc` | `kiro-cli plugin uninstall jsc-git@jsc` | | kiro | `kiro-cli plugin marketplace add https://gitea.jsc.idv.tw/plugins/meta.git && kiro-cli plugin install jsc-git@jsc` | `kiro-cli plugin marketplace update jsc && kiro-cli plugin update jsc-git@jsc` | `kiro-cli plugin uninstall jsc-git@jsc` |
> antigravity 不支援 gitea URL 安裝,改用本地 clone 路徑。批次操作五個 CLI:使用 `/jsc-cli:deploy`。 > antigravity 不支援 gitea URL 安裝,改用本地 clone 路徑。批次操作五個 CLI:使用 `/jsc-cli:deploy`。
> 舊入口 `plugins/jsc` 已移除,marketplace 正本移到 `plugins/meta`。marketplace 名稱仍是 `jsc`(取自 marketplace.json 的 `name` 欄位,與存取庫名無關),安裝 token 不變;已從舊入口安裝過的人先執行 `claude plugin marketplace remove jsc`,再依上表重新 add。
## Skills 目錄 ## Skills 目錄
呼叫方式:Claude / Antigravity `/jsc-git:{name}`;Codex `${name}`;Copilot / Kiro 描述需求自動觸發。 呼叫方式:Claude / Antigravity `/jsc-git:{name}`;Codex `${name}`;Copilot / Kiro 描述需求自動觸發。
@@ -36,7 +38,7 @@ Marketplace 統一為 `jsc`(https://gitea.jsc.idv.tw/plugins/jsc.git),安
| 檔案 | 用途 | | 檔案 | 用途 |
| --- | --- | | --- | --- |
| `templates/pr-description.md` | PR 描述:摘要 / 變更內容 / 設計重點 / 測試結果 / 前置 PR | | `templates/pr-description.md` | PR 描述:摘要、變更內容、設計重點、測試結果、前置 PR |
## 相關 domain ## 相關 domain
+1 -1
View File
@@ -1,6 +1,6 @@
{ {
"name": "jsc-git", "name": "jsc-git",
"version": "0.0.1", "version": "0.0.4",
"description": "Commit 分組認可與 Push Request 建立", "description": "Commit 分組認可與 Push Request 建立",
"skills": "./skills/" "skills": "./skills/"
} }
+25 -25
View File
@@ -3,38 +3,38 @@ name: commit
description: Group all pending file changes by conventional type and feature, then commit each group as {type}({scope}): {message}. Message style is full (What/Why/How/Who), brief (one line from git diff), or custom, chosen via decision tree. Use whenever changes must be committed; not for push or PR creation. description: Group all pending file changes by conventional type and feature, then commit each group as {type}({scope}): {message}. Message style is full (What/Why/How/Who), brief (one line from git diff), or custom, chosen via decision tree. Use whenever changes must be committed; not for push or PR creation.
--- ---
# commit — 分組認可檔案變更 # commit — group and commit file changes
## 步驟 ## Steps
1. 追蹤所有檔案變更:先 `git status --porcelain` 檢視全部變更,再逐組 `git add`(不可盲目 `git add -A` 後一次 commit)。 1. Track every file change: inspect all changes with `git status --porcelain` first, then `git add` group by group. Never `git add -A` and commit everything at once.
2. 依「同類型 + 同需求/功能」將檔案變更分組,一組一個 commit。 2. Group the changes by same type plus same requirement or feature. One group is one commit.
3. 每組依格式認可:`{類型}({需求 or 功能}): {訊息}`。 3. Commit each group with the format `{type}({requirement or feature}): {message}`.
## 類型表 ## Type table
| 類型 | 用途 | | Type | Purpose |
| --- | --- | | --- | --- |
| feat | 新增/修改功能 | | feat | add or change a feature |
| fix | 修補 bug | | fix | fix a bug |
| docs | 文件 | | docs | documentation |
| style | 格式(不影響程式碼運行的變動) | | style | formatting; no change to how the code runs |
| refactor | 重構(既不是新增功能,也不是修補 bug 的程式碼變動) | | refactor | code change that neither adds a feature nor fixes a bug |
| perf | 改善效能 | | perf | improve performance |
| test | 增加測試 | | test | add tests |
| chore | 建構程序或輔助工具的變動 | | chore | build process or tooling change |
| revert | 撤銷回覆先前的 commit | | revert | revert an earlier commit |
## 訊息格式(三選一) ## Message format (pick one of three)
依 `jsc-ask:ask` 規則詢問使用者;問詢紀錄或本 session 已有慣例就不再問。 Ask the user per the `jsc-ask:ask` rules. Skip the question when the question record or this session already holds a convention.
1. **完整版**:包含做什麼(What)、為什麼做(Why)、怎麼做(How)、哪個功能做(Who)。 1. **Full**: covers What, Why, How, and Who (which feature).
2. **簡易版**:根據 `git diff` 總結出一句描述。 2. **Brief**: one sentence summarized from `git diff`.
3. **自訂**:使用者自行輸入訊息。 3. **Custom**: the user types the message.
## 規則 ## Rules
1. 分組與訊息草擬的細節**必須以 sub agent 執行**,主 agent 只確認分組結果與執行 commit。 1. The grouping and message drafting details **MUST run as a sub agent**. The main agent only confirms the grouping and runs the commits.
2. 訊息一律 UTF-8 繁體中文(類型與 scope 除外)。 2. Write messages in UTF-8 Traditional Chinese (the type and scope stay in English), per the STE100 output rule.
3. 不可 push;push 與 PR 由 `jsc-git:pr` 負責。 3. Never push. Push and PR belong to `jsc-git:pr`.
+21 -21
View File
@@ -1,29 +1,29 @@
--- ---
name: pr name: pr
description: Commit all changes via jsc-git:commit, create a target branch named from the highest-priority commit type plus a summarized title, push, then open a Gitea PR with the templated description. Branch priority is revert > fix > feat > perf > refactor > test > docs > style > chore. Use when work is ready for review; not for plain commits. description: Commit all changes via jsc-git:commit, create a target branch named from the highest-priority commit type plus a summarized title, push, then open a Gitea PR with the templated description against the base branch the caller passed in (falling back to develop, main, master only when none was given). Branch priority is revert > fix > feat > perf > refactor > test > docs > style > chore. Use when work is ready for review; not for plain commits.
--- ---
# pr — 建立 Push Request # pr — create a Push Request
## 步驟 ## Steps
1. 呼叫 `jsc-git:commit` 將所有檔案變更認可完成。 1. Call `jsc-git:commit` to commit every file change first.
2. 決定來源分支:遠端存在 `develop` 就用 `develop`,否則用 `main`(再否則用 `master`)。 2. Pick the base branch. **A base branch passed in by the caller wins over everything else** — `jsc-sdlc:implement` passes the analysis page's source branch, and silently retargeting that PR at `develop` would merge a single work package straight past the feature branch it belongs to. Only when no caller supplied one: use `develop` when it exists on the remote, else `main`, else `master`. Verify the chosen base exists on the remote (`git fetch --prune origin` first, then `git branch -r`); it does not exist → report and stop, never fall back silently.
3. 從遠端來源分支建立目標分支: 3. Create the target branch from the remote base branch:
1. 類型取所有 commit 中優先度最高者:`revert > fix > feat > perf > refactor > test > docs > style > chore`。 1. Take the type with the highest priority across all commits: `revert > fix > feat > perf > refactor > test > docs > style > chore`.
2. 標題從所有 commit 的訊息總結出一句。 2. Summarize one title from all commit messages.
3. 分支名**只允許 ASCII**,一律 slug 化:`{類型}/{需求 or 功能}-{標題}`。需求/功能與標題先翻譯成英文短語,再轉小寫、非 `a-z0-9` 字元以連字號取代、連續連字號合併、頭尾連字號移除(例:`feat/order-匯出報表` → `feat/order-export-report`)。不可含空白、括號、冒號與任何非 ASCII 字元。 3. Branch names allow **ASCII only**; always slugify as `{type}/{requirement or feature}-{title}`. Translate the requirement and title into a short English phrase first, then call `tools/slugify.sh {type} {phrase}` to produce the final slug (example: translate a non-English request to English first, then slugify — "export report" → export-report → feat/order-export-report). No spaces, parentheses, colons, or any non-ASCII character.
4. `git push -u origin {目標分支}`。 4. Run `git push -u origin {target branch}`.
5. 建立 PR:`jsc-gitea/tools/gitea.sh pr-create {owner}/{repo} {目標分支} {來源分支} "{分支名}" {描述檔}`。 5. Create the PR: `jsc-gitea/tools/gitea.sh pr-create {owner}/{repo} {target branch} {base branch} "{branch name}" {description file}`.
- 標題 = 分支名。 - Title = branch name.
- 描述先套用 `templates/pr-description.md` 寫入暫存檔再帶入。 - Write the description into a temp file first, using `templates/pr-description.md` (a Traditional Chinese template; the generated description stays in Traditional Chinese per the STE100 output rule).
6. **前置 PR 阻擋**:描述中有前置 Push Request 時,執行 6. **Prerequisite PR blocking**: when the description lists a prerequisite Push Request, run
`jsc-gitea/tools/gitea.sh pr-depend {owner}/{repo} {本 PR 編號} {前置 owner}/{repo} {前置 PR 編號}` `jsc-gitea/tools/gitea.sh pr-depend {owner}/{repo} {this PR number} {prerequisite owner}/{repo} {prerequisite PR number}`
把本 PR 掛上依賴;前置 PR 未關閉前 Gitea 會阻擋合併,避免誤合併。API 不可用時降級:PR 標題加 `WIP:` 前綴(Gitea 原生阻擋合併),前置完成後移除。 to add the dependency. Gitea then blocks merging until the prerequisite PR closes. If the API is unavailable, degrade: prefix the PR title with `WIP:` (Gitea blocks merging natively) and remove it once the prerequisite is done.
7. 回報 PR URL。 7. Report the PR URL.
## 規則 ## Rules
1. 描述範本各節不可留空:沒有計畫/分析頁就填「無」,沒有前置 PR 就填「無」。 1. No template section may stay empty: fill the literal 「無」 when there is no plan page, analyze page, or prerequisite PR.
2. 計畫頁與分析頁連結由 `jsc-sdlc` 的 wiki 頁取得;分析頁連結必須導向工作包標題錨點。 2. Take the plan page and analyze page links from the `jsc-sdlc` wiki pages; the analyze link must point at the work package heading anchor.
3. 描述草擬的細節**必須以 sub agent 執行**。 3. Branch title summarization (step 3.2) and description drafting MUST run as a sub agent.
+20
View File
@@ -0,0 +1,20 @@
#!/usr/bin/env sh
# slugify.sh — 把分支類型與描述轉成 ASCII 分支名 slug。
# 用法: slugify.sh {type} {phrase}
# 規則: 全部轉小寫,非 a-z0-9 的字元換成連字號,
# 連續連字號合併成一個,並去除開頭與結尾的連字號。
# 輸出: {type}/{slug}(例如: slugify.sh feat "export report" → feat/export-report)
set -u
if [ "$#" -lt 2 ]; then
echo "用法: slugify.sh {type} {phrase}" >&2
exit 1
fi
TYPE="$1"
shift
PHRASE="$*"
slug=$(printf '%s' "$PHRASE" | tr '[:upper:]' '[:lower:]' | sed -e 's/[^a-z0-9]/-/g' -e 's/-\{2,\}/-/g' -e 's/^-//' -e 's/-$//')
printf '%s/%s\n' "$TYPE" "$slug"