skills/github-issue-run/SKILL.md
Orchestrate GitHub feature:<slug> backlog — next-runnable discovery, state transitions, flat or stage execution loop. Delegate gh and lib scripts to developer.
npx skillsauth add roborew/opencode github-issue-runInstall 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.
Companion to orchestrate-execution when working from a GitHub feature:<slug> backlog (no local .plan artifact).
env_gate_passed) or no (env_gate_declined) before work selection.opencode-task-yaml with non-empty stages[] for orchestrate level).gh authenticated (via delegated developer Tasks).feature:<slug> and state:ready-for-agent (or transitioned to state:in-progress during execution).OC="${OPENCODE_CONFIG:-$HOME/.config/opencode}"
"$OC/skills/github-issue-run/lib/next-runnable-issue.sh"
"$OC/skills/github-issue-run/lib/issue-state-transition.sh"
"$OC/skills/github-issue-run/lib/feature-finish-pr.sh"
Task developer load: minimal:
bash "$OC/skills/github-issue-run/lib/next-runnable-issue.sh" "<slug>"
Stdout is JSON: { number, title, body, opencode_meta, repo } or empty (exit 1 = queue exhausted).
Parse opencode_meta from opencode-task-yaml (primary) or legacy opencode-task-json.
Task developer load: minimal:
bash "$OC/skills/github-issue-run/lib/issue-state-transition.sh" "<repo>" "<number>" "<state-label>"
| When | Label |
|------|-------|
| Start work | state:in-progress |
| Verifier PASS (all stages done for issue) | state:ready-for-review |
| Blocked / env failure | state:blocked |
| Accepted after Mode F Phase 1 | state:done (set by architect — orchestrate must not use this label) |
state:in-progress.opencode_meta.stages is non-empty → follow stage loop in orchestrate-execution (execution_mode: github_issue_stage).execution_mode: github_issue) using root acceptance + test_commands from meta.git_commit with Refs: #<n> when files changed.state:ready-for-review + optional gh issue comment with summary + commit hash. Do not run CodeRabbit per issue.state:blocked or helper / orchestrate-recovery — do not advance queue.When next-runnable-issue.sh exits 1 (no runnable issues left):
easy, orchestrate runs the CodeRabbit gate from orchestrate-execution on all feature changes before PR finish — defaulting to develop as base. Per-issue transitions must not invoke CodeRabbit, and remediation must not re-run CodeRabbit.load: minimal:bash "$OC/skills/github-issue-run/lib/feature-finish-pr.sh" "<slug>"
Stdout is JSON: { branch, base, pr_url, pr_number, action, repo, message }.
| action | Meaning |
|----------|---------|
| pr-created | Branch pushed; new ready-for-review PR opened |
| pr-exists | Branch pushed; reused existing open PR |
| skipped-opt-out | ORCHESTRATE_AUTO_PR=0 or user asked not to open a PR |
| skipped-protected-branch | Current branch is develop/main/master — push/PR skipped; report message and manual next steps |
pr_url (or skip reason) and feature ### CodeRabbit completion fields to the user.architect for feature sign-off (Mode F two-phase: verify + close issues, then docs on PR).Orchestrate must not set state:done, close issues as accepted, or write docs/changelog/* — that is architect Mode F (architect-review, helper architect-review/lib/mode-f-close-issues.sh).
Opt-out: Set ORCHESTRATE_AUTO_PR=0 in the environment, or tell orchestrate not to open a PR for this run.
Base branch: Defaults to develop, falling back to the repo default branch if develop is absent on origin. Override with PR_BASE env or pass as second script argument.
If helper scripts are missing, stop and report — do not fall back to inventing queue logic. Local .plan execution remains a separate orchestrate path when user provides an artifact path explicitly.
tools
AI-powered code review using CodeRabbit CLI. Use only on explicit user request or when parent passes execution_mode orchestrate_coderabbit_gate. Do not run during orchestrated stage/issue work.
tools
Cross-repo companion to to-prd: after PRD frontmatter is filled, run bin/fanout <slug> from this spec repo to create child GitHub issues (one per ticket or legacy slice).
tools
Issue state machine — transition GitHub issue labels per docs/agents/triage-labels.md. Batch helpers via lib/triage.sh.
documentation
Synthesise a PRD from grill-me / research context, write docs/prd/<slug>.md, publish a GitHub issue with prd + state:ready-for-agent + feature:<slug>. Halt after publish — do not invoke fanout.