skills/handoff/SKILL.md
Generate a copy-ready handoff prompt for transferring work context to a new session. TRIGGER when: user asks to hand off work, create a handoff prompt, transfer context, wrap up session, prepare for next session (e.g., "handoff 해줘", "다음 세션으로 넘겨줘", "작업 이관해줘", "handoff prompt 만들어줘"). DO NOT TRIGGER when: user is committing, creating PRs, reviewing code, or performing other git operations without handoff intent.
npx skillsauth add chanmuzi/git-conventions handoffInstall this skill globally with one command. Works with Claude Code, Cursor, and Windsurf.
3 of 9 scanners reported clean
Some scanners were skipped, did not run, or reported a non-clean status. Review each row below.
1. Next-action relevance. Include only information the next session needs to act. Completed work from this session belongs in the handoff only if it is a precondition for the next task. The question to ask for every bullet: "If I remove this, where does the next session get stuck?" — if nothing breaks, drop it. The handoff is not a session recap.
2. Reference, never repeat. If a spec, plan, or document exists, reference its path. The handoff prompt contains only: (1) pointers to existing artifacts, (2) session context not captured elsewhere, (3) a directive for the next session's first action.
Parse $ARGUMENTS to determine the handoff mode.
| Argument | Type | Description |
|----------|------|-------------|
| topic | Optional string | Focus filter — handoff concentrates on this topic only (e.g., /handoff auth 리팩토링) |
| -y | Optional flag | Skip confirmation — output handoff prompt directly without draft review |
If $ARGUMENTS contains -y, extract it as the skip-confirmation flag. The remaining text (if any) is the topic filter.
If $ARGUMENTS is empty, proceed with auto-detection and default confirmation flow.
Run the following detection layers in priority order. Each layer enriches the handoff context.
Layer 0 — Topic Override
If a topic was provided in $ARGUMENTS, use it to scope the handoff. The topic guides which parts of the session context to include. Continue to subsequent layers for context detection, but filter all results through this topic.
Layer 1 — Sentinel Skill Detection (Zero-cost)
Check if these sentinel skill names exist in the current session's available skills. This is zero-cost: no Bash, no filesystem reads — check the session's context window for skill names.
| Sentinel | Plugin | What it enables |
|----------|--------|-----------------|
| oh-my-claudecode:autopilot | OMC | Recommend /autopilot or /ralph for spec/plan-based execution |
| git-claw:commit | git-claw (self) | Recommend /commit for uncommitted changes |
| git-claw:pr | git-claw (self) | Recommend /pr for committed changes without PR |
Store detected sentinels for use in the skill recommendation step.
Layer 2 — Conversation Context Analysis
Analyze the current conversation to identify what the next session needs to act, not to summarize what this session did. This is the primary context source — it always runs and is never a fallback.
Extract from the next-session perspective:
Exclusion criteria — drop these even if they happened in this session:
The output of this layer scopes all subsequent layers — Layer 3 (Git) and Layer 4 (Artifact Search) are filtered through this understanding.
If a topic filter was provided (Layer 0), focus the analysis accordingly.
This layer triggers the confirmation flow (unless -y flag is set or a relevant artifact is found in Layer 4), because conversation-derived summaries need user validation before handoff.
Layer 3 — Git State Detection
Gather current git state:
git branch --show-current
git status --short
git diff --stat
git log --oneline -5
git stash list
Use these as data inputs for the 상황 section, applying the Next-action relevance filter from the Core Principles — include each item only when it gates the next action:
git log output as a session recapLayer 4 — Artifact Search (Context-Scoped)
Search for existing structured artifacts using the Glob tool:
Glob: .omc/specs/*.md
Glob: .omc/plans/*.md
Combine results from both patterns.
Important: Only select artifacts that are relevant to the conversation context identified in Layer 2. Artifacts from other sessions or unrelated work MUST be ignored. The conversation context is the filter — not the other way around.
If relevant artifacts are found:
If no relevant artifacts are found, proceed with conversation-derived context from Layer 2.
Construct the handoff using the two-zone output structure.
Display detection results to the user for transparency. This zone is NOT part of the handoff prompt and will not be included when the user runs /copy.
Show:
Separate the Meta Zone and Handoff Zone with a clear --- divider.
Wrap the entire Handoff Zone in a fenced code block with the language set to markdown. This enables /copy to present it as a selectable item in the picker UI, so the user can copy only the handoff content without the Meta Zone.
The handoff prompt always opens with a directive — 1~3 lines that tell the next session what to do first.
The tone does not need to be strictly imperative. Natural phrasing is fine as long as the intended action is unambiguous.
Below the directive, add structured context by selecting from the section pool. Each section uses a bold heading followed by bullets.
| Section | Purpose | When to include |
|---------|---------|-----------------|
| 상황 | Entry preconditions for the next action — minimum facts the next session needs to start, plus git metadata | Always |
| 원인 | Diagnosed root cause of a problem | Bug/issue where root cause was identified |
| 진행 상황 | Completed vs remaining work | Work is partially done |
| 판단 필요 사항 | Options and criteria for a pending decision | Direction not yet determined |
| 조사 결과 | Investigation/analysis findings | Research done, execution not started |
| 참고 | Files, PRs, issues, artifact paths, branches | References exist (almost always) |
Composition rules:
상황 is always present. 참고 is present whenever references exist.원인, 진행 상황, 판단 필요 사항, 조사 결과) based on the scenario. Do not include sections that have no content.참고. Never copy artifact content inline — reference by path only.상황 as inline info, not as a standalone section.Anti-patterns — do not do these:
상황 as a session recap ("we merged X, decided Y, closed Z") instead of entry preconditions for the next action.git log --oneline -5 items in 상황 or 참고 when those commits are not entry preconditions.참고 with PRs/issues that the next session has no reason to open.Typical combinations — adapt based on actual session content, not rigid templates.
Clear task — directive + 상황 + 원인 + 참고:
{project}에서 {problem}을 {approach}로 해결할 것.
**상황**
- {background and current state}
- Branch: `{branch}` / Status: {state}
**원인**
- {root cause analysis}
**참고**
- {files, PRs, etc.}
Direction needed — directive + 상황 + 판단 필요 사항 + 참고:
{project}에서 아래 이슈의 영향 범위를 진단하고
대응 방식을 결정하여 작업 계획을 제시할 것.
**상황**
- {background and current state}
**판단 필요 사항**
- {option A vs option B, criteria}
**참고**
- {files, PRs, etc.}
Partial progress — directive + 상황 + 진행 상황 + 참고:
{artifact} 참고하여 {next step}부터 이어서 진행할 것.
**상황**
- {background and what this session was about}
- Branch: `{branch}` / Status: {state}
**진행 상황**
- {completed items}
- {remaining items}
**참고**
- Spec: {artifact_path}
Investigation complete — directive + 상황 + 조사 결과 + 참고:
아래 조사 결과를 바탕으로 {topic}에 대한 구현 방향을
결정하고 작업을 시작할 것.
**상황**
- {background}
**조사 결과**
- {key findings}
- {implications}
**참고**
- {files, PRs, etc.}
Skill continuation (minimal) — directive + 상황:
/autopilot으로 {artifact} 참고하여 {next step}부터 진행.
**상황**
- {brief context}
- Branch: `{branch}` / Status: {state}
Based on sentinel detection (Layer 1) + context type (Layers 2-4):
| Context | OMC Available | No OMC | Strategy |
|---------|---------------|--------|----------|
| Spec exists (.omc/specs/) | /autopilot or /ralph | "spec 참고하여 작업 진행" | Spec-driven execution |
| Plan exists (.omc/plans/) | /autopilot | "plan 참고하여 작업 진행" | Plan-driven execution |
| Code changes (uncommitted) | /commit | /commit | Stage and commit first |
| Committed, no PR | /pr | /pr | Create PR |
| Conversation only | Context-dependent | Plain task description | Varies by topic |
Important: Weave the skill name into the directive line so that copy-paste triggers the skill directly:
/autopilot으로 spec 참고하여 Step 4부터 진행Step 4부터 진행 (추천: /autopilot)Before showing the draft (or before final output when -y / artifact-present path skips confirmation), apply the next-action relevance test to every bullet across all sections.
For each bullet, ask:
"If this bullet is removed, where does the next session get stuck?"
Apply the same check to 참고: every PR / issue / file path must be something the next session will actually consult to perform its first action — not a session-history dump.
If a section ends up empty after pruning, omit it entirely.
Conversation analyzed → Relevant artifact found? ──yes──→ Output directly
│
no
│
├── -y flag? ──yes──→ Output directly
│
no
│
└── Show draft → user reviews and uses `/copy` or requests modifications
/copy to accept, or requests modifications.Do NOT append confirmation questions like "이 내용으로 handoff 하면 될까요?" — the code block output is self-evident. If the user wants changes, they will ask.
Output the final handoff prompt to the terminal. The user can then use /copy to copy it for the next session.
Important:
development
Review PR comments, discuss improvements, and reply with resolution status. TRIGGER when: user asks to review PR feedback, check review comments, address reviewer suggestions, or handle code review (e.g., "리뷰 확인해줘", "review comments", "피드백 반영해줘"). DO NOT TRIGGER when: user is creating PRs, committing, or performing git operations without review intent.
tools
Create a pull request following project conventions. TRIGGER when: user asks to create/open a PR, push and create PR, or any workflow that includes PR creation (e.g., "PR 올려줘", "푸시하고 PR 만들어줘", "commit, push, and create PR"). DO NOT TRIGGER when: user is viewing or listing existing PRs, or performing git operations without PR intent.
documentation
Create a GitHub issue following project conventions with auto-labeling. TRIGGER when: user asks to create an issue, report a bug, request a feature, file a ticket, or track work (e.g., "이슈 만들어줘", "버그 리포트", "feature request", "이거 이슈로 만들어줘"). DO NOT TRIGGER when: user is viewing, listing, or commenting on existing issues without intent to create a new one.
testing
Create a git commit following project conventions. TRIGGER when: user asks to commit, create a commit, stage and commit, save changes, or any workflow that includes committing (e.g., "commit and push", "commit and create PR", "커밋해줘", "커밋하고 푸시"). DO NOT TRIGGER when: user is only checking git status/diff without intent to commit.