본문으로 건너뛰기
cccskills
무료GitHub에 공개

gh-stack

Manage dependent branches and pull requests with the GitHub gh-stack extension. Plan their order, inspect relationships, propagate changes through higher branches, and handle synchronization or conflict recovery using the documented workflow.

한국어 요약은 준비 중입니다. 영어 요약을 표시하고 있습니다.

원문원문 설명 보기

Manage Cherry Studio stacked branches and pull requests with the GitHub gh-stack extension. Use for planning, creating, inspecting, rebasing, syncing, linking, or recovering a stack of dependent PRs.

연동 도구GitHub
설치 방법 보기

이럴 때 유용합니다

  • Plan dependent changes across multiple pull requests
  • Propagate lower-branch fixes through dependent branches
  • Inspect and link existing pull requests
  • Recover from rebase conflicts

포함된 파일(1)

  • SKILL.md5.3 KB

SKILL.md(원문)

설치하기 전에 에이전트에게 전달되는 지시 내용을 확인할 수 있습니다.

GitHub Stack

Use gh stack for branch topology and synchronization. Use the repository's gh-create-pr skill for Cherry-specific PR bodies, Spec approval, AC coverage, verification, and Agent Note lifecycle.

Availability and prerequisites

This public skill is tracked in .agents/skills/ and discovered from the repository. Developers do not install a separate agent skill. pnpm skills:sync maintains the .claude/skills/ compatibility symlink.

Run this preflight before the first gh stack command in a task:

command -v gh >/dev/null 2>&1 || {
  echo "GitHub CLI is required: https://cli.github.com/" >&2
  exit 1
}
gh auth status
if ! gh stack --help >/dev/null 2>&1; then
  gh extension install github/gh-stack
fi
gh stack --help >/dev/null

If GitHub CLI authentication, extension installation, or the final verification fails, stop and report the failing command. Do not guess stack topology with ad hoc branch comparisons.

Before initializing a stack, avoid extension prompts:

git config rerere.enabled true

When multiple remotes exist, resolve the intended remote and pass --remote <name> to commands that accept it. Do not silently change remote.pushDefault for the developer.

Stack model

A stack is a linear dependency chain. The bottom branch is closest to the trunk; each higher branch contains only work that depends on the layer below it.

main
  -> spec
    -> implementation-core
      -> implementation-ui

Plan the complete dependency order before creating branches. Put a newly discovered lower-layer change on its owning branch, then rebase the upstack branches; do not hide it in the current layer.

Agent-safe commands

All commands must be non-interactive:

  • Always run gh stack view --json; plain view opens a TUI.
  • Always supply branch names to init, add, and checkout.
  • Always use --auto with submit if that command is explicitly allowed.
  • Pass --remote <name> to push, submit, sync, or link when more than one remote exists.
  • Use ordinary git add and git commit -S --signoff so each layer is staged deliberately.

Common operations:

gh stack init --base main <bottom-branch> [<higher-branch>...]
gh stack add <new-top-branch>
gh stack view --json
gh stack push --remote <remote>
gh stack rebase --upstack --remote <remote>
gh stack sync --remote <remote>
gh stack checkout <branch-or-pr>
gh stack link --remote <remote> <bottom-pr> <higher-pr> [...]

Exit code 2 from gh stack view --json means only that the current checkout has no matching local stack metadata. It does not prove that an existing PR is standalone on GitHub. In a clean disposable worktree, run gh stack checkout <pr-number-or-url> to discover and hydrate remote topology, then rerun gh stack view --json. Classify an existing PR as standalone only after remote discovery confirms that it is not attached to a GitHub stack.

Exit code 3 means a conflict, but recovery depends on the command. gh stack rebase leaves active recovery state, so resolve the conflict and run gh stack rebase --continue, or gh stack rebase --abort. gh stack sync rolls the attempted rebase back before returning; start a new gh stack rebase to resolve that conflict, and do not use --continue or --abort unless a rebase is active. Exit code 9 means GitHub stacked PRs are unavailable for the repository; stop instead of silently publishing a different PR shape.

Cherry PR creation

Do not use gh stack submit --auto to create human-authored Cherry PRs. It creates PRs before the required body preview and auto-generates bodies that do not satisfy the repository template.

Create a compliant stack bottom-up:

  1. Push the branches with gh stack push --remote <remote>.
  2. Invoke gh-create-pr for each layer, using the parent branch as that layer's base.
  3. After every PR has its approved title and body, link the existing PRs with gh stack link --remote <remote> <bottom-pr> <higher-pr> [...].
  4. Verify the resulting topology with gh stack view --json.

gh stack submit --auto is allowed only for an explicitly authorized automation workflow that is exempt from the human PR template. It is not a shortcut around Cherry's preview requirement.

Changes to an existing stack

When changing a lower layer:

  1. Check out that branch explicitly.
  2. Make and verify the focused change there.
  3. Run gh stack rebase --upstack --remote <remote>.
  4. Push or sync the stack.
  5. For every rewritten live PR, rerun pnpm change:scope --base <verified-parent-ref> and only the checks invalidated by that rewritten scope.

After gh stack sync, inspect its output and run gh stack view --json; a successful command alone is not proof that each PR still has the intended base, scope, or verification.

Lifecycle boundary

Follow .agents/skills/agent-notes/SKILL.md for Spec approval and lifecycle transitions. Intermediate implementation layers keep the note proposed. Only the final layer whose cumulative, actually-run evidence covers every approved AC may move the bilingual note triplet to implemented/.

리뷰

아직 리뷰가 없습니다. 사용해 본 소감을 남겨 주세요.

댓글

로그인 없이 쓸 수 있습니다. 사용 후기, 질문, 작동하지 않은 환경 등을 편하게 남겨 주세요.

아직 댓글이 없습니다. 첫 댓글을 남겨 보세요.

보내면 바로 공개됩니다. 이메일 주소나 전화번호 같은 개인 정보는 쓰지 마세요. URL은 2개까지입니다.

0 / 1,000자

이 양식은 reCAPTCHA로 보호되며 Google 개인정보처리방침 및 서비스 약관이 적용됩니다.

같은 저장소의 스킬

Record durable Cherry Studio engineering decisions in Agent Notes. Determine which changes need a note, prepare specifications with verifiable acceptance criteria, and manage approval, implementation, rejection, and replacement while preserving the reasoning behind decisions.

한국어 요약은 준비 중입니다. 영어 요약을 표시하고 있습니다.

  • Deciding whether a change needs a lasting decision record
  • Documenting bug fixes with significant tradeoffs
  • Preparing specifications for approval before implementation
CherryHQ/cherry-studio5.3만2026년 10월 19일 업데이트

Get answers about Cherry Studio from the installed version’s product information. The skill explains features, settings locations, and shortcuts, provides clickable navigation entries, and helps diagnose connection failures, configuration problems, and runtime errors.

한국어 요약은 준비 중입니다. 영어 요약을 표시하고 있습니다.

  • Finding a feature or settings page
  • Checking supported providers and default shortcuts
  • Diagnosing connection failures and runtime errors
CherryHQ/cherry-studio5.3만2026년 10월 19일 업데이트

Operate the visible browser pane in a Cherry Studio conversation to navigate pages, click controls, fill forms, capture screenshots, and investigate browser issues. It can work with authenticated websites while checking page state and action outcomes.

한국어 요약은 준비 중입니다. 영어 요약을 표시하고 있습니다.

  • Navigate and operate an authenticated website
  • Fill forms and verify the resulting page state
  • Capture screenshots of a page or specific section
CherryHQ/cherry-studio5.3만2026년 10월 19일 업데이트

Operates native desktop apps through Cherry Studio Computer Use. It reads interface information, types, clicks, and captures windows, using fresh observations to choose actions and verify results within the permissions and capabilities available.

한국어 요약은 준비 중입니다. 영어 요약을 표시하고 있습니다.

  • Open a desktop app and inspect its interface
  • Enter text and click controls in an app
  • Capture a window when interface details are unclear
CherryHQ/cherry-studio5.3만2026년 10월 19일 업데이트

Develop and verify changes in a tracked Cherry Studio Electron instance, a running desktop app. Use real UI behavior, logs, and performance measurements to investigate problems, compare fixes, or test a pull request and report the results.

한국어 요약은 준비 중입니다. 영어 요약을 표시하고 있습니다.

  • Implement UI changes and verify them in the app
  • Reproduce bugs and inspect runtime logs
  • Compare performance before and after a fix
CherryHQ/cherry-studio5.3만2026년 10월 19일 업데이트

Run repeatable tests of Cherry Studio’s key workflows with Playwright, which checks application behavior through automated interactions. Collect results on macOS and Windows and produce English reports for release acceptance or development validation.

한국어 요약은 준비 중입니다. 영어 요약을 표시하고 있습니다.

  • Checking key workflows before a release
  • Validating application behavior on a development branch
  • Running regression tests for a specific task
CherryHQ/cherry-studio5.3만2026년 10월 19일 업데이트

CherryHQ의 스킬 모두 보기

이 스킬의 문제 신고