| ํญ๋ชฉ | ๋ด์ฉ |
|---|---|
| Invoke | /zenhub:manage |
| Category | kobic-workflow |
| Complexity | simple |
| MCP Servers | zenhub |
/zenhub:manage โ ZenHub ์ด์ยทPR ์ํ ์ ๋ฆฌ ๋์ฐ๋ฏธ#
ํ๋ง๋๋ก#
์์ ์งํ ์ํฉ์ ๋ง์ถฐ ZenHub ๋ณด๋์ ์นด๋(์ด์)๋ฅผ ์๋ง์ ์นธ์ผ๋ก ์ฎ๊ธฐ๊ณ , ์ฝ๋ ๋ณ๊ฒฝ(PR)๊ณผ ์ด์๋ฅผ ์๋ก ์ฐ๊ฒฐํด ์ฃผ๋ ๋๊ตฌ์ ๋๋ค. ์นธ๋ฐ ๋ณด๋์์ ํฌ์คํธ์์ "์งํ ์ค โ ๊ฒํ ์ค โ ์๋ฃ"๋ก ์ฎ๊ฒจ ๋ถ์ด๋ ์ผ์ ๋์ ํด ์ค๋ค๊ณ ๋ณด๋ฉด ๋ฉ๋๋ค.
๋๊ฐยท์ธ์ ์ฐ๋์#
- PR(์ฝ๋ ๋ณ๊ฒฝ ๋ฌถ์)์ ๋ง๋ ๋ค, ๊ทธ PR์ ๊ด๋ จ ์ด์์ ์ฐ๊ฒฐํด์ผ ํ ๋
- ์์ ๋จ๊ณ๊ฐ ๋ฐ๋์ด์ ๋ณด๋์ ์ด์ ์์น(ํ์ดํ๋ผ์ธ)๋ฅผ ์ฎ๊ฒจ์ผ ํ ๋
- ์์ ์ ์์ํ์ ๋, ๋ฆฌ๋ทฐ๋ฅผ ์์ฒญํ ๋, ๋ณํฉ(merge)์ด ๋๋ฌ์ ๋
๋ฌด์์ ํด์ฃผ๋์#
- PR๊ณผ ์ด์๋ฅผ ์ฐ๊ฒฐํด ์ค๋๋ค (GitHub์
Closes #์ด์๋ฒํธํค์๋ ํ์ฉ) - ์ด์๋ฅผ ์ ์ ํ ๋ณด๋ ์นธ์ผ๋ก ์ด๋์์ผ ์ค๋๋ค โ ์:
In Progress,Review/QA - ์ด์์ PR์ ํ์ฌ ์ํ๋ฅผ ํ์ธํด ์ค๋๋ค
- ๋ณํฉ ํ์๋ ์ด์๊ฐ ์๋์ผ๋ก ๋ซํ๋์ง ํ์ธํ๊ณ , ์ ๋ซํ์ผ๋ฉด ๋์ ๋ซ์ ์ค๋๋ค
-
๋ณด๋์ ์นธ ๋ชฉ๋ก์ ํ๋ก์ ํธ๋ง๋ค ๋ค๋ฅด๋ฏ๋ก, ์ฒ์ ์คํํ ๋ ์๋์ผ๋ก ์กฐํํฉ๋๋ค (๋ํ ์นธ: New Issues, Icebox, Product Backlog, Sprint Backlog, In Progress, Review/QA โ
Done/Closed์นธ์ ์์, ๋ซํ์ GitHub state)
์ด๋ป๊ฒ ์ฐ๋์#
# PR์ ์ด์์ ์ฐ๊ฒฐ
/zenhub:manage link-pr --pr 1627 --issue 1413
# ์ด์๋ฅผ ํน์ ๋ณด๋ ์นธ์ผ๋ก ์ด๋
/zenhub:manage move --issue 1413 --to " Review/QA "
# ์ด์ยทPR ์ํ ํ์ธ
/zenhub:manage status --issue 1413
link-prโ PR๊ณผ ์ด์๋ฅผ ์ฐ๊ฒฐํฉ๋๋ค-
move --to "์นธ ์ด๋ฆ"โ ์ด์๋ฅผ ํด๋น ๋ณด๋ ์นธ์ผ๋ก ์ฎ๊น๋๋ค (์:"In Progress","Review/QA") statusโ ์ด์๋ PR์ ํ์ฌ ์ํ๋ฅผ ๋ณด์ฌ ์ค๋๋ค
์์์ ๋ฌด์จ ์ผ์ด ๋ฒ์ด์ง๋์#
์์ ํ๋ฆ์ ๋ง์ถฐ ๋ณดํต ๋ค์ ์์๋ก ์งํ๋ฉ๋๋ค.
- ์์
์์ โ ์ด์๋ฅผ
In Progress์นธ์ผ๋ก ์ฎ๊น๋๋ค. -
PR ์์ฑ ํ โ PR ๋ณธ๋ฌธ์
Closes #์ด์๋ฒํธ๋ฅผ ๋ฃ์ด GitHub๊ฐ ์๋ ์ฐ๊ฒฐํ๊ฒ ํ๊ณ , ์ด์๋ฅผReview/QA์นธ์ผ๋ก ์ฎ๊น๋๋ค. -
๋ณํฉ ํ โ
Closes #ํค์๋ ๋๋ถ์ GitHub ์ด์๊ฐ ์๋์ผ๋ก ๋ซํ๊ณ ZenHub๋Closed๋ก ๋๊ธฐํ๋ฉ๋๋ค. (Done์นธ์ผ๋ก๋ ์ฎ๊ธฐ์ง ์์ต๋๋ค โDone์ "๋ซํ"๊ณผ ๋ค๋ฆ ๋๋ค.) ์๋์ผ๋ก ๋ซํ์ง ์์์ผ๋ฉด ์ง์ ๋ซ์ ๋ง๋ฌด๋ฆฌํฉ๋๋ค.
์ฐธ๊ณ : ZenHub์์๋ PR์ ์ด์์ ํ์ ํญ๋ชฉ์ผ๋ก ๋ ์ ์์ต๋๋ค. ๊ทธ๋์ GitHub์
Closes #ํค์๋๋ก ์ฐ๊ฒฐํ๊ณ , ์ํ ๊ด๋ฆฌ๋ ๋ณด๋ ์นธ ์ด๋์ผ๋ก ํฉ๋๋ค. ๊ทธ๋ฆฌ๊ณ Epic > Story > Sub-task ๊ณ์ธต ๊ตฌ์กฐ๋ฅผ ์ ์งํฉ๋๋ค.
โ๏ธ ์์ธ ์ต์ ยท์คํ ๋ช ์ธ (๊ฐ๋ฐ์ / AI ์์ด์ ํธ์ฉ)
Triggers#
- When issue linking is needed after PR creation
- When pipeline state updates are needed
- On work progress state changes
Context Trigger Pattern#
/zenhub:manage {action} [--options]Actions#
| Action | Description | Example |
|---|---|---|
link-pr | Link PR to issue | /zenhub:manage link-pr --pr 1627 --issue 1413 |
move | Move issue to pipeline | /zenhub:manage move --issue 1413 --to "Review/QA" |
status | Check issue/PR status | /zenhub:manage status --issue 1413 |
Pipeline Query#
Pipeline IDs differ per project workspace. Dynamically queried on first call:
const workspace = await mcp__zenhub__getWorkspacePipelinesAndRepositories();
// workspace.pipelines โ [{ id, name }, ...]
// Live pipelines (6): New Issues, Icebox, Product Backlog, Sprint Backlog, In Progress, Review/QA
// (no " Done " / " Closed " column โ close via gh issue close + updateIssue state:CLOSED)Workflow Patterns#
1. On Work Start#
# Move issue to In Progress
/zenhub:manage move --issue {issue_number} --to " In Progress "2. After PR Creation#
# Include " Closes #{issue_number} " in PR body (GitHub auto-link)
# Move issue to Review/QA
/zenhub:manage move --issue {issue_number} --to " Review/QA "3. After Merge (merge = Close)#
# Issue auto-closes via " Closes # " keyword in PR body โ ZenHub syncs to Closed.
# Never move to Done (Done โ closed). Verify + fallback:
# gh issue view {n} --json state โ if not CLOSED: gh issue close {n} --reason completed
# searchClosedIssues " #{n} " โ if missing: updateIssue state:CLOSEDPR Linking Best Practices#
GitHub Auto-Link Keywords#
Include the following keywords in PR body for GitHub auto-linking:
## Related Issue
- Closes #1413
- Fixes #1413
- Resolves #1413ZenHub Linking Limitations#
- PRs cannot be set as children of issues in ZenHub
- Using GitHub's "Closes #" keyword is recommended
- In ZenHub, manage state via pipeline moves
MCP Tool Usage#
Issue Search#
mcp__zenhub__searchLatestIssues({ query: " 1413 " })Pipeline Move#
// Query workspace info (on first call)
const workspace = await mcp__zenhub__getWorkspacePipelinesAndRepositories();
const reviewPipeline = workspace.pipelines.find(p = > p.name === " Review/QA " );
// fail-closed: ๋ชป ์ฐพ์ผ๋ฉด throw (์ด๋ฆ ๋ถ์ผ์น ์ undefined.id ๋ฌด์ ๋๋ฝ ๋ฐฉ์ง)
if (!reviewPipeline) throw new Error(` ' Review/QA ' ํ์ดํ๋ผ์ธ ์์. ๋ผ์ด๋ธ: ${workspace.pipelines.map(p = > p.name).join( " , " )}`);
mcp__zenhub__moveIssueToPipeline({
issueId: " {issue_graphql_id} " ,
pipelineId: reviewPipeline.id
})Repository / Issue Type / Organization Query#
All IDs differ per project workspace. Dynamically query based on the X-zh-workspace header configured in .mcp.json:
// Repository ID + Pipeline ID
const workspace = await mcp__zenhub__getWorkspacePipelinesAndRepositories();
// Issue Type ID
const issueTypes = await mcp__zenhub__getIssueTypes();Key Rules#
- On PR Creation: Include
Closes #{issue}in body - On Work Start: Move to In Progress
- On Review Request: Move to Review/QA
- After Merge (merge = Close):
Closes #auto-closes GitHub โ ZenHub syncs to Closed. Never use Done (Done โ closed); verify GitHubclosed+ ZenHubClosedand fall back togh issue close/updateIssue state:CLOSED - Epic Structure: Maintain Epic > Story > Sub-task hierarchy