End-to-end pull request automation: create branches, commit changes, open PRs, monitor CI, auto-fix failures, and merge — all from your terminal.
npx clawhub@latest install github-pr-workflowGitHub PR Workflow automates the full pull request lifecycle on GitHub — from branch creation and commit drafting through CI monitoring, auto-fixing failing checks, and final merge with branch cleanup. Install it if you want to ship code changes without manually juggling git commands, gh CLI flags, or the GitHub web UI. It works with the gh CLI when available and falls back to git plus the GitHub REST API via curl.
gh CLI authenticated or a GitHub PAT available; without one of those, API calls will fail.Automatically creates a feature branch with a conventionally named slug and stages your changes with a generated commit message. Keeps your commit history clean without requiring you to write messages manually.
Pushes the branch to origin and opens a pull request using a built-in description template (references/pr-template.md). Supports reviewer requests, label assignment, and issue linking in the same step.
Polls GitHub check runs via scripts/watch_ci.sh and prints the logs of any failing checks directly to your session. No more clicking through the Actions UI to find the error.
When a check fails, the skill can apply a fix, push the new commit, and re-poll checks — repeating the cycle until all required checks pass. Saves back-and-forth pushes when dealing with linting or formatting failures.
Supports squash merge, rebase merge, and standard merge commits. After merging, it deletes the source branch to keep the remote tidy.
Uses the gh CLI as the primary driver when it is authenticated. If gh is unavailable, references/api-fallback.md and curl-based scripts handle all operations against the GitHub REST API using $GITHUB_TOKEN.
A developer has local changes and asks: "Open a PR titled 'Add rate limiting to /api/search' targeting main." The skill creates the branch, stages commits, pushes, and opens the PR with a description — no manual git commands needed.
After opening a PR, a developer asks: "Watch the PR checks, and if lint fails, fix and push again." The skill polls check runs, detects the lint failure, applies the fix, pushes, and re-checks until the suite is green.
When review is approved, a developer asks: "Squash-merge PR #142 and delete the branch." The skill executes the squash merge and removes the remote branch in one action.
A developer asks: "Review my branch — what checks are failing and who hasn't approved yet?" The skill surfaces current CI status and outstanding reviewer approvals from the GitHub API.
Required on the host machine:
git installed and configured with user identitygh CLI authenticated via gh auth login or a GitHub Personal Access Token (PAT) exported as $GITHUB_TOKENcurl (used by the REST API fallback scripts when gh is unavailable)Repository requirements:
Optional / environment tuning:
GH_PAGER=cat in large monorepos to avoid pager interference with script outputnpx clawhub@latest install github-pr-workflownpx clawhub@latest install github-pr-workflowLog in to write a review
No reviews yet. Be the first to share your experience!