From openspec-toolkit
Create a PR with title and body generated from OpenSpec spec artifacts
npx claudepluginhub pmco23/claude-code-openspec-toolkit## Context
- Active change: !`find openspec/changes -maxdepth 1 -mindepth 1 -type d ! -name archive -printf '%T@ %f\n' 2>/dev/null | sort -rn | head -1 | awk '{print $2}' || echo "none"`
- Proposal: !`find openspec/changes -maxdepth 2 -name "proposal.md" ! -path "*/archive/*" -printf '%T@ %p\n' 2>/dev/null | sort -rn | head -1 | awk '{print $2}' | xargs cat 2>/dev/null || echo "no proposal"`
- Tasks: !`find openspec/changes -maxdepth 2 -name "tasks.md" ! -path "*/archive/*" -printf '%T@ %p\n' 2>/dev/null | sort -rn | head -1 | awk '{print $2}' | xargs cat 2>/dev/null || echo "no tasks.md"`.../prCreates GitHub pull request from current feature branch using gh CLI. Checks repo state, pushes branch, generates title from git log and summary body from changes.
/prRuns pre-PR quality gates (tests, typecheck, lint, code review) then creates GitHub pull request with structured summary and test plan. Supports --skip-review, --draft, --base flags.
/prPerforms code quality review on GitHub Pull Requests: analyzes diff for test coverage, idiomatic patterns, DRY/SOLID compliance, and build verification. Supports language (go/python/rust/typescript/java) and project profiles.
Share bugs, ideas, or general feedback.
find openspec/changes -maxdepth 1 -mindepth 1 -type d ! -name archive -printf '%T@ %f\n' 2>/dev/null | sort -rn | head -1 | awk '{print $2}' || echo "none"find openspec/changes -maxdepth 2 -name "proposal.md" ! -path "*/archive/*" -printf '%T@ %p\n' 2>/dev/null | sort -rn | head -1 | awk '{print $2}' | xargs cat 2>/dev/null || echo "no proposal"find openspec/changes -maxdepth 2 -name "tasks.md" ! -path "*/archive/*" -printf '%T@ %p\n' 2>/dev/null | sort -rn | head -1 | awk '{print $2}' | xargs cat 2>/dev/null || echo "no tasks.md"cat .github/pull_request_template.md 2>/dev/null || cat .github/PULL_REQUEST_TEMPLATE.md 2>/dev/null || cat docs/pull_request_template.md 2>/dev/null || echo "NO_TEMPLATE"git status --shortgit branch --show-currentgit log --oneline main..HEAD 2>/dev/null || git log --oneline -10git diff --stat main..HEAD 2>/dev/null || echo "no diff from main"Create a pull request from the current OpenSpec change. Follow these steps:
Branch — If on main, create a feature branch: git switch -c openspec/<change-name>.
Stage and commit — If there are uncommitted changes, stage and commit them using the same format as /commit (conventional commit referencing the change name and tasks).
Push — Push the branch to origin with -u.
Create PR — Use gh pr create with:
<change-name> converted to a human-readable sentence (e.g., add-dark-mode → Add dark mode)If a PR template was found (the context above does NOT show NO_TEMPLATE):
Use the template as the structure. Fill in each section using the spec artifacts:
OpenSpec change: <change-name> at the bottomIf no PR template was found (NO_TEMPLATE):
Use this default structure:
## Summary
<1-3 sentences from proposal.md explaining the motivation and approach>
## Changes
<bullet list of completed tasks from tasks.md>
## Test plan
<checklist of verification steps based on tasks.md acceptance criteria>
---
OpenSpec change: `<change-name>`
Use a HEREDOC to pass the body.
Output — Print only the PR URL.
You have the capability to call multiple tools in a single response. Do all steps in as few messages as possible. Do not send any other text besides tool calls and the final PR URL.