From issue-pr-flow
Issue-driven development workflow on GitHub or GitLab. Detects platform, checks repo readiness, branches by intent (feature/bug/chore), and drives the issue → PR → merge loop, composing with feature-dev for heavy features. User-invoked only via /issue-pr-flow:issue-pr-flow.
How this skill is triggered — by the user, by Claude, or both
Slash command
/issue-pr-flow:issue-pr-flowThe summary Claude sees in its skill listing — used to decide when to auto-load this skill
You are driving a developer through an issue-tracked development cycle on either GitHub (via `gh`) or GitLab (via `glab`). The aim is to make every meaningful change traceable: an issue describes intent, a branch carries the work, a PR/MR captures the diff and review, and merge closes the loop. You handle the orchestration; the platform CLIs do the talking; the user makes the calls.
assets/templates/github/ISSUE_TEMPLATE/bug-report.mdassets/templates/github/ISSUE_TEMPLATE/chore.mdassets/templates/github/ISSUE_TEMPLATE/feature-request.mdassets/templates/github/labels.jsonassets/templates/github/pull_request_template.mdassets/templates/github/workflows/ci.ymlassets/templates/gitlab/issue_templates/Bug.mdassets/templates/gitlab/issue_templates/Chore.mdassets/templates/gitlab/issue_templates/Feature.mdassets/templates/gitlab/labels.jsonassets/templates/gitlab/merge_request_templates/Default.mdreferences/init.mdreferences/platform-github.mdreferences/platform-gitlab.mdreferences/route-bugfix.mdreferences/route-chore.mdreferences/route-feature.mdreferences/scripts.mdscripts/apply_labels.shscripts/detect_env.shYou are driving a developer through an issue-tracked development cycle on either GitHub (via gh) or GitLab (via glab). The aim is to make every meaningful change traceable: an issue describes intent, a branch carries the work, a PR/MR captures the diff and review, and merge closes the loop. You handle the orchestration; the platform CLIs do the talking; the user makes the calls.
feature-dev:feature-dev workflow and keep this skill responsible for the issue/PR wrapping. Don't re-implement codebase exploration here.CLAUDE.md (and sibling docs the user already maintains), not in this conversation. After substantial work, suggest CLAUDE.md updates so future sessions don't relearn the same lessons.The whole skill operates on the current working directory's git repo. Two common entry states:
cd'd into a clone — proceed.gh repo clone <owner>/<repo> / glab repo clone <group>/<project> / git clone <url> and cd in. Don't try to run any of this skill's scripts before the working directory is the repo.If detect_env.sh returns {"platform":"unknown","reason":"not_a_git_repo",...}, that's the signal to do the clone-and-cd dance above.
bash ${CLAUDE_PLUGIN_ROOT}/skills/issue-pr-flow/scripts/detect_env.sh
This reports: platform (github / gitlab / unknown), platform_source (how it was inferred: env / url / cli / unknown), host, remote URL, owner/repo slug, default and current branch, per-host CLI auth status, and recommended_cli + ready flags. See references/scripts.md for the full schema.
URL substring matching only catches github.com and gitlab.<tld>. Self-hosted GitHub Enterprise or GitLab on an IP address (e.g. http://10.100.181.168/group/repo) or a custom domain falls through. When that happens the script tries one more rule — if exactly one of gh / glab is authenticated for this host, take its hint — but if both or neither are authed for the host, you'll get platform: unknown.
Resolve it by:
IPF_PLATFORM=gitlab bash …/detect_env.sh (or github). Use this same env var for init_check.sh too.glab auth login --hostname <host> or gh auth login --hostname <host> once. Don't try to authenticate on their behalf — this is interactive and account-sensitive.For self-hosted GitLab specifics (HTTP vs HTTPS API protocol, ssh vs https git protocol), see references/platform-gitlab.md.
If after all of the above:
brew install gh / brew install glab); don't fall back to raw curl against the API, you lose the CLI's auth handling and paginationauth login and confirm before retryingOnce ready: true, all subsequent platform commands route through the matching CLI. See references/platform-github.md or references/platform-gitlab.md for the command tables. Pick one CLI and stick to it for the rest of the session unless the user switches repos.
Run the bundled init check (pass IPF_PLATFORM if Phase 0 needed it):
bash ${CLAUDE_PLUGIN_ROOT}/skills/issue-pr-flow/scripts/init_check.sh
# or, for self-hosted on an IP / custom domain:
IPF_PLATFORM=gitlab bash ${CLAUDE_PLUGIN_ROOT}/skills/issue-pr-flow/scripts/init_check.sh
It reports the objective, fixed-path facts: issue templates, PR/MR template, CI config file paths, and the live label list. If platform is unknown the script returns {"error":"platform_unknown",...} instead of an empty report — that's the cue to set IPF_PLATFORM and re-run, not to assume the repo has nothing.
The script intentionally does not evaluate CI health or test infrastructure — those are too varied to pattern-match reliably. When they need to be assessed, you do it by reading the project (build manifest, README, CI files, git history) and asking the user as needed. references/init.md §4b walks the CI health questions and §5 walks the test-infrastructure assessment.
Do not create or push anything based on this report — just summarize the gaps and ask whether the user wants to backfill them. Init covers six categories, each its own confirmation: issue templates → PR template → labels → CI (existence + health) → test infrastructure (existence + health) → CLAUDE.md. Group related changes into one commit per category and explain what the commit will contain before running git add.
If the user says "skip init for now" — respect that and move on to Phase 2 immediately. The check is opportunistic, not a gate.
Ask the user (or infer from their initial message) which of these the work is:
| Route | When | Reference |
|---|---|---|
| feature | New capability, cross-module change, anything that may need an ADR or architecture discussion | references/route-feature.md |
| bug | Reproducible defect with a known wrong behavior to fix | references/route-bugfix.md |
| chore | Docs, deps bumps, config tweaks, small refactors with no behavior change | references/route-chore.md |
If the user is ambiguous ("just make it work better"), ask one targeted clarifying question rather than guessing. Misrouting bugs as features wastes time on exploration; misrouting features as chores skips needed design.
Once routed, read the corresponding reference file in full before continuing. Each reference encodes the route's checklist, branch naming, label set, commit message conventions, and the issue/PR template for that route. Don't try to remember the rules from this SKILL.md — go read the source of truth for the route.
Each route is a sequence of: create issue → branch → implement (route-specific) → push → open PR → CI green → review → merge → cleanup. The reference files spell out the platform-specific commands.
Two things this SKILL.md owns regardless of route:
feature-dev:feature-dev workflow on the implementation portion only. Wrap its output back into your issue/PR. Don't let it open the PR — you own that to keep label/template conventions consistent.After the PR merges, ask whether anything from this work should land in CLAUDE.md (or a sibling docs/DECISIONS.md style file if the repo has one). Good candidates: a non-obvious convention you discovered, a constraint that bit you mid-implementation, an architectural decision worth recording. Bad candidates: routine commit details, anything reconstructible from git log.
If the user agrees, propose a concrete diff to CLAUDE.md and commit it as a follow-up (separate from the feature PR — typically directly to the default branch if the project allows, otherwise as a tiny chore PR). The point is to keep future Claude sessions from relearning the same context.
skills/issue-pr-flow/
├── SKILL.md (this file — entry point and orchestration)
├── references/
│ ├── platform-github.md gh command table, auth, edge cases
│ ├── platform-gitlab.md glab command table, auth, edge cases
│ ├── init.md issue template / label palette / CI starters
│ ├── route-feature.md feature route: full ceremony, feature-dev hand-off
│ ├── route-bugfix.md bug route: reproduce → locate → fix → test → PR
│ ├── route-chore.md chore route: lightweight, single-commit PRs
│ └── scripts.md schemas + usage for the bundled scripts
├── scripts/
│ ├── detect_env.sh platform + CLI + auth probe → JSON
│ ├── init_check.sh templates / labels / CI presence report → JSON
│ └── apply_labels.sh sync repo labels from a JSON palette (gh/glab)
└── assets/templates/
├── github/ issue templates, PR template, labels.json, ci yml
└── gitlab/ issue templates, MR template, labels.json, ci yml
Read references on demand — don't load them all upfront. Run scripts via bash ${CLAUDE_PLUGIN_ROOT}/skills/issue-pr-flow/scripts/<name>.sh so paths resolve regardless of where the user invokes you.
gh/glab commands without first running detect_env.sh — you'll either use the wrong tool or hit a missing-auth error mid-flow.platform: unknown as "no platform" and giving up — for self-hosted instances on IP / custom domain, set IPF_PLATFORM=github|gitlab and retry. Don't silently switch to writing files and skipping the platform commands.feature-dev:feature-dev and let its code-explorer / code-architect / code-reviewer agents do their job.Guides creation, editing, and verification of skills for AI coding agents using test-driven development with subagent scenarios. Use when authoring or debugging skills.
npx claudepluginhub anthoooooooony/atn-claude-code-plugins