Generic GitHub workflow commands for Claude Code. Provides a complete development workflow from issue creation through release.
Most GitHub automation tools embed assumptions about your repository:
- Branch names like
mainormasterare hardcoded - Labels are assumed to exist
- PR templates are project-specific
- Commands break when you customize your workflow
This creates fragile automation that works in demos but fails in real projects with real conventions.
Every command discovers your repository's actual configuration at runtime:
- Default branch? Detected via
gh repo view - Available labels? Fetched via
gh label list - Repository name? Queried, not assumed
This means the same commands work across all your repositories without modification.
Traditional issue tracking often fails because issues describe how to implement something rather than what needs to be achieved:
| Brittle Issue | Solution-Agnostic Issue |
|---|---|
| "Add DateFilter component to src/components/views/" | "Users can filter results by date" |
| "Refactor UserService to use dependency injection" | "Authentication should be testable in isolation" |
| "Update the onClick handler in Button.tsx" | "Click actions should provide feedback" |
Why this matters: When you refactor your codebase, solution-agnostic issues remain valid. Issues that specify file paths become obsolete the moment code moves.
gh-workflow's /gh-issue command guides you toward solution-agnostic issue creation, ensuring your backlog survives refactoring.
Every command uses the AskUserQuestion tool at moments where your input matters:
- Which branch type? (feature vs fix vs docs)
- Which labels to apply?
- Ready to create this PR?
This isn't just confirmation prompts — it's structured decision-making that prevents mistakes while keeping you in control.
Critical principle: Before asking for any decision, commands must display the findings that inform that decision.
❌ Wrong: "What review decision would you like to submit?"
(User hasn't seen what the review found)
✅ Right: "Here are the review findings: [detailed list]
Now, what review decision would you like to submit?"
Users need to see the evidence before making decisions. Every decision prompt follows the pattern:
- First, display the complete findings/preview
- Then, invoke the AskUserQuestion tool with options
Rather than a collection of unrelated commands, gh-workflow provides an integrated workflow:
Issue → Branch → Implementation → PR → Review → Merge → Release
Each step knows about the others. /gh-start reads the issue you're implementing. /gh-review knows what the PR is supposed to accomplish. This context-awareness improves quality at every stage.
Irreversible actions (force push, branch deletion, release creation) require explicit approval. But routine operations flow smoothly with sensible defaults.
- Zero Configuration: Commands auto-detect repository settings (default branch, labels, etc.)
- Interactive: Uses the AskUserQuestion tool for guided workflows
- Portable: Works with any GitHub repository without hardcoding
- Customizable:
/gh-setupgenerates project-specific configurations - Quality Checks: Detects tech stack and runs appropriate lint/test commands
- Safety Hooks: Prevents irreversible actions without explicit user approval
- Task-Based Tracking: Uses TaskCreate/TaskUpdate for implementation and review progress
- Multi-Faceted Review: Structured review with P1/P2/P3 prioritization
- Capability Discovery: Dynamically discovers available agents, skills, and quality commands
- Runtime Verification: Verifies implementation works when running (dev server, API, E2E)
- Self-Review Gates: Mandatory code and test review before PR creation
gh-workflow is designed for fully AI-driven development where humans define intent (via /gh-issue) and AI handles implementation through merge. The Comprehension Layer ensures humans can understand what AI built, why it made the choices it did, and whether those choices align with the original intent.
| Component | Purpose |
|---|---|
| Decision Journal | Records significant decisions post-hoc from diffs at .decisions/issue-{N}.md |
| Human Gates | Configurable pauses at high-stakes decisions via decision-journal skill (new deps, security, schema changes) |
| Comprehension Report | Architecture narratives embedded in PR bodies with requirements adherence |
| Interactive Q&A | /gh-explain loads full context for conversational exploration |
Configuration lives in .claude/settings.gh-workflow.json (generated by /gh-setup):
{
"$schema": "https://raw.githubusercontent.com/synaptiai/synapti-marketplace/main/plugins/gh-workflow/schema.json",
"gates": {
"newDependencies": "on",
"securityChanges": "on",
"schemaChanges": "on",
"apiSurfaceChanges": "on",
"scopeDeviations": "on",
"ambiguousRequirements": "on"
}
}Gate values: on (pause for approval), log (record without pausing), off (skip). All default to on.
Three config scopes are supported (local > project > user), each with its own file. See references/gate-configuration.md for full configuration options including per-command toggles, report thresholds, and journal settings. See references/config-reading.md for the complete JSON path reference.
| Command | Description |
|---|---|
/gh-workflow:gh-issue |
Create a new GitHub issue with solution-agnostic principles |
/gh-workflow:gh-start <N> |
Start work on issue #N (branch, implement, ready for PR) |
/gh-workflow:gh-commit |
Context-aware commits with change classification |
/gh-workflow:gh-pr |
Create PR with full review and reviewer suggestions |
/gh-workflow:gh-review <N> |
Review PR #N with checklist and feedback |
/gh-workflow:gh-address <N> |
Address review comments on PR #N |
/gh-workflow:gh-merge <N> |
Merge approved PR #N |
/gh-workflow:gh-release [type] |
Create a release (patch/minor/major) |
/gh-workflow:gh-status |
Show workflow status overview (assigned issues, open PRs, review requests) |
/gh-workflow:gh-explain [N] |
Explore what AI built — loads context for interactive Q&A |
/gh-workflow:gh-security-review |
Security review of branch changes (secrets, injection, auth, deps) |
/gh-workflow:gh-setup |
Analyze repo and generate workflow configuration |
What's Good About /gh-issue:
- Duplicate detection — Searches existing issues before creating, preventing redundant work
- Solution-agnostic enforcement — Guides you away from implementation details that become stale
- Structured templates — Consistent format (Context, Objective, Acceptance Criteria) across all issues
- Label validation — Fetches actual available labels, prevents typos and missing labels
What's Good About /gh-start:
- Complete workflow — One command handles: assign issue, pull latest main, create branch, implement
- Branch naming conventions — Enforces consistent naming (feature/issue-N, fix/issue-N, docs/issue-N)
- Task-based implementation — Creates tasks from acceptance criteria and tracks progress
- Capability discovery — Discovers available agents and skills before implementation
- Self-review gates — Mandatory code review, test review, and pre-PR gate
- Parallel execution — Maximizes efficiency with parallel API calls and file reads
- Flexible ending — Choose to create PR immediately, defer to
/gh-pr, or continue working
What's Good About /gh-commit:
- Change classification — Automatically classifies changes as in-context, uncertain, or out-of-context
- External change flagging — Flags unrelated files (config, editor settings) before committing
- Multiple commits support — Groups related changes for atomic commits
- Branch context awareness — Uses branch name, linked issue, and active tasks for classification
- Conventional commits — Enforces commit message conventions (feat:, fix:, docs:, etc.)
What's Good About /gh-pr:
- Full code review — Mandatory code review with P1/P2/P3 prioritized findings before PR
- Convention check — Validates commit messages and branch naming
- Reviewer suggestions — Suggests reviewers based on CODEOWNERS, file expertise, and workload
- Quality gates — Runs lint, test, and type-check commands before PR
- Preview before creation — Shows complete PR preview and requires explicit approval
- Decoupled from gh-start — Can be run independently after any commit workflow
What's Good About /gh-review:
- Context-aware — Reads the linked issue to understand what the PR should accomplish
- Structured checklist — Systematic review categories prevent overlooking important aspects
- Interactive feedback — Guides through approval, request changes, or comment-only decisions
- Quality gates — Detects tech stack and suggests appropriate lint/test commands to run
- Multi-faceted review — Creates tasks for each review facet (code quality, conventions, security, tests, requirements)
- Prioritized findings — Categorizes issues as P1 (critical), P2 (important), P3 (suggestions)
- Finding synthesis — Consolidates all findings into a structured summary with decision logic
- Parallel execution — Reads multiple files and creates tasks in parallel for efficiency
What's Good About /gh-address:
- Comment aggregation — Pulls all review comments into a single actionable list
- Systematic resolution — Track which comments have been addressed
- Conversation continuity — Maintains context of the review discussion
- Task-based tracking — Creates tasks for each feedback item and tracks resolution
- Post-address review gate — Re-runs code review and quality checks after fixes
- Quality verification — Ensures fixes don't introduce new issues before pushing
What's Good About /gh-merge:
- Safety checks — Verifies PR is approved and checks are passing
- Branch cleanup — Optionally deletes feature branch after merge
- Merge strategy selection — Choose squash, merge commit, or rebase based on preference
What's Good About /gh-release:
- Semantic versioning — Guided selection of patch/minor/major increment
- Automatic changelog — Generates release notes from merged PRs since last release
- Tag creation — Creates git tag and GitHub release in one step
- Version consistency — Updates version numbers in project files if detected
What's Good About /gh-status:
- Quick overview — See all your assigned issues, open PRs, and review requests in one view
- Attention flags — Highlights PRs with unaddressed feedback or failing checks
- No context switching — Get status without leaving your terminal
- Read-only — Safe to run anytime, doesn't modify anything
What's Good About /gh-explain:
- Context loading — Loads decision journal, diff, issue, and source files into a single conversation
- Comprehension brief — Displays a summary of what was built, key decisions, and requirements status
- Interactive Q&A — Ask questions grounded in actual code and decisions, not guesswork
- Session saving — Optionally saves Q&A sessions for future reference
- Graceful degradation — Works even without a decision journal (falls back to diff + issue)
What's Good About /gh-setup:
- Setup or update — Works for both first-time setup and updating existing installations
- Tech stack detection — Identifies Python, TypeScript, Go, Ruby and configures appropriate quality commands
- Template generation — Creates customized issue/PR templates based on your conventions
- Non-destructive — Shows preview of changes before writing any files
- Version-aware updates — Detects installed version, shows what's new, preserves customizations
- Backup safety — Creates timestamped backups before modifying existing configurations
What's Good About /gh-security-review:
- Dedicated security scanning — Focused review separate from general code review
- CWE-referenced findings — Every finding maps to a known vulnerability category
- Six scan phases — Secrets, injection, auth/authz, data exposure, dependency audit, remediation
- Actionable output — Every finding includes file:line location and suggested fix
- Scoped scanning — Can limit to specific categories (secrets, injection, auth, deps)
- Dependency auditing — Runs package-manager-specific audit tools when available
/gh-workflow:gh-setup
This analyzes your repository and generates a customized workflow configuration in your .claude/CLAUDE.md or CLAUDE.md file.
Commands work without setup by auto-detecting your repository's settings:
/gh-workflow:gh-issue Add user authentication
┌─────────────────┐
│ /gh-status │ View assigned issues, PRs, review requests
└────────┬────────┘
▼
┌─────────────────┐
│ /gh-issue │ Create issue with context, objectives, criteria
└────────┬────────┘
▼
┌─────────────────┐
│ /gh-start N │ Assign issue, create branch, implement
└────────┬────────┘
▼
┌─────────────────┐
│ /gh-commit │ Context-aware commits (optional, can repeat)
└────────┬────────┘
▼
┌─────────────────┐
│ /gh-pr │ Full review, reviewer suggestions, create PR
└────────┬────────┘
▼
┌─────────────────┐
│ /gh-review N │ Review PR, provide feedback
└────────┬────────┘
▼
┌─────────────────┐
│ /gh-address N │ Address review comments (if any)
└────────┬────────┘
▼
┌─────────────────┐
│ /gh-merge N │ Merge approved PR, delete branch
└────────┬────────┘
▼
┌─────────────────┐
│ /gh-release │ Create release with changelog
└─────────────────┘
Commands never hardcode values. Instead, they detect:
- Default branch:
gh repo view --json defaultBranchRef - Repository name:
gh repo view --json nameWithOwner - Available labels:
gh label list
Issues describe WHAT, not HOW:
- ✅ "User can filter results by date"
- ❌ "Add DateFilter component to src/components/"
This ensures issues remain valid even when implementation details change.
Every command uses the AskUserQuestion tool at decision points:
- Label selection
- Branch type choice
- PR approval
- Review decisions
After running /gh-setup, you can customize:
- CLAUDE.md: Edit the workflow section for project-specific conventions
- Local commands: Copy commands to
.claude/commands/for customization - Labels: Create additional labels specific to your project
The templates/ directory contains:
CLAUDE-workflow.md- Workflow section templateissue-template.md- Issue body structurepr-template.md- PR body structure
- GitHub CLI (
gh) installed and authenticated - Git repository with GitHub remote
- Claude Code with plugin support
The plugin includes specialized agents for different aspects of the workflow:
Generic code quality reviewer that analyzes:
- Logic correctness and edge cases
- Security patterns and vulnerabilities
- Error handling assessment
- Code quality and best practices
Validates Git conventions including:
- Commit message format (conventional commits)
- Branch naming patterns
- PR format compliance
- Issue linkage verification
Discovers and executes project-specific quality commands:
- Tech stack detection (Python, Node, Go, Rust)
- Command discovery from CLAUDE.md
- Lint, test, and type-check execution
- Result reporting with failure details
Analyzes issues and creates task breakdowns:
- Parses acceptance criteria from issues
- Creates tasks using TaskCreate
- Identifies dependencies between tasks
- Tracks implementation progress
Provides dynamic repository configuration detection. Used internally by all commands to:
- Detect default branch
- Get repository info for API calls
- Fetch available labels
Discovers available capabilities in the user's environment:
- Scans for custom agents and skills
- Parses CLAUDE.md for quality commands
- Detects tech stack
- Enables dynamic workflow adaptation
Discovers and executes runtime verification for the implementation:
- Dev server startup and health checks
- API endpoint smoke testing
- E2E test framework detection and execution
- Acceptance criteria verification
- Graceful degradation when capabilities are missing
Captures, structures, and persists significant decisions made during AI-driven workflow execution:
- Post-hoc extraction from completed diffs (not AI self-reporting)
- Human gate detection for high-stakes changes (new dependencies, security, schema, API surface)
- Sensitivity classification (public/internal) for decision entries
- Three modes:
init(create journal),log(extract decisions + gates),summarize(condense for PR) - Used by
/gh-start,/gh-commit,/gh-pr,/gh-address
Generates architecture narratives that help humans understand what AI built:
- Two-tier reports: minimal (< threshold lines) and full (5 sections)
- Requirements adherence mapping (Met / Interpreted / Partially Met / Not Addressed)
- Architecture decisions from decision journal
- System connection analysis
- Verification checklists for human review
- Used by
/gh-prand/gh-address
Provides intelligent user suggestions for reviewers and assignees:
- Matches CODEOWNERS file patterns
- Analyzes recent PR activity and file contributors
- Balances workload across team members
- Used by
/gh-pr,/gh-review,/gh-address, and/gh-issue
The plugin includes safety hooks that:
- Pre-push verification: Ensures user approval before irreversible git operations
- Pre-release verification: Ensures user approval before creating GitHub releases
- Destructive operation guard: Warns before force push, hard reset, or branch deletion
- Repository target verification: Confirms correct repo before creating issues or PRs
- Post-edit reminders: Notes test files to verify after source file modifications
- Workflow completion check: Verifies all phases completed before stopping
- Task completion verification: Validates acceptance criteria met when marking tasks done
The /gh-setup command detects your project's tech stack and generates appropriate quality checklists:
| Stack | Detection | Quality Commands |
|---|---|---|
| Python | pyproject.toml, ruff.toml |
ruff check, pytest |
| TypeScript | package.json, tsconfig.json |
npm run lint, npm test |
| Go | go.mod |
go vet, go test |
| Ruby | Gemfile, .rubocop.yml |
rubocop, rspec |
/gh-workflow:gh-status
/gh-workflow:gh-issue Add dark mode support to the dashboard
/gh-workflow:gh-start 42
/gh-workflow:gh-review 15
/gh-workflow:gh-release minor
Situation: You have a feature request from a stakeholder.
# 1. Create a well-structured issue
/gh-workflow:gh-issue Users need to export their data as CSV
# 2. Start work (assigns issue, creates branch, begins implementation)
/gh-workflow:gh-start 42
# 3. Commit changes as you work (context-aware)
/gh-workflow:gh-commit
# 4. Create PR with full review and reviewer suggestions
/gh-workflow:gh-pr
# 5. Reviewer reviews the PR
# (reviewer uses /gh-review 15)
# 6. Address any feedback
/gh-workflow:gh-address 15
# 7. Merge when approved
/gh-workflow:gh-merge 15Result: Complete audit trail from stakeholder request to merged code, with consistent structure at every step.
Situation: Production bug reported, needs quick turnaround.
# 1. Create issue (duplicate check ensures we're not re-solving old bugs)
/gh-workflow:gh-issue Users see error when clicking submit button
# 2. Branch type selection guides toward fix/ prefix
/gh-workflow:gh-start 43
# → Creates: fix/issue-43-submit-error
# 3. Fast implementation, PR created
# → PR title includes "fixes #43" for auto-close
# 4. Emergency merge (after quick review)
/gh-workflow:gh-merge 16Result: Bug fix with proper tracking, even under time pressure.
Situation: Sprint complete, time to release.
/gh-workflow:gh-release minorWhat happens:
- Detects last release tag
- Collects all merged PRs since then
- Generates changelog from PR titles/descriptions
- Prompts for version confirmation (1.2.0 → 1.3.0)
- Creates git tag and GitHub release
Result: Professional release notes without manual changelog maintenance.
- Less context switching — One command handles the full workflow instead of multiple manual git/gh operations
- Consistent quality — Templates and checklists ensure nothing is forgotten
- Fewer mistakes — Interactive prompts catch issues before they become problems
- Uniform issue quality — Every issue follows the same structure
- Predictable branches — Naming conventions make branch purpose clear
- Traceable history — PRs link to issues, releases link to PRs
- Onboarding efficiency — New team members follow the same guided workflow
- Refactoring-safe backlog — Solution-agnostic issues remain valid when code moves
- Audit compliance — Complete trail from requirement to release
- Reduced friction — Less time on process, more time on implementation
MIT