merge-pr

Squash-merge GitHub pull requests with validation and cleanup.

3|1|Updated Feb 23, 2026
One-click install
npx skills add https://github.com/SeanHogg/coderClaw --skill merge-pr-seanhogg
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: merge-pr
Source: https://github.com/SeanHogg/coderClaw/tree/main/.coderClaw/.agents/archive/merge-pr-v1
Command: npx skills add https://github.com/SeanHogg/coderClaw --skill merge-pr-seanhogg

SYSTEM DOCUMENTATION & REQUIREMENTS

💡 This Skill includes scripts (resource) components.

What problem does it solve?

This Skill automates the process of merging prepared GitHub Pull Requests (PRs) using a squash merge strategy, ensuring a clean commit history and efficient integration of changes.

Core Features & Use Cases

  • Automated Squash Merging: Merges PRs using gh pr merge --squash with explicit attribution.
  • Pre-Merge Validation: Verifies PR state, checks required GitHub Actions, and ensures the branch is not behind main.
  • Worktree Isolation: Performs all merge operations within a dedicated worktree to prevent interference with the main repository.
  • Post-Merge Cleanup: Removes the worktree and temporary branches only after a successful merge.
  • Use Case: After a PR has been reviewed and prepared by another agent, use this skill to finalize the merge into the main branch, automatically handling commit attribution and cleanup.

Quick Start

Use the merge-pr skill to merge pull request number 123.

Frequently Asked Questions about merge-pr

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I automate a GitHub PR squash merge with pre-merge validation?

This skill automates squash merging by verifying the PR state, checking required GitHub Actions, ensuring the branch is not behind main, and executing the merge with proper commit attribution.

What does a squash merge do to my git commit history?

A squash merge condenses all pull request commits into a single commit on the main branch. This skill automates the process while validating required checks and ensuring the branch is not behind main.

Can I use a dedicated git worktree to isolate PR merge operations?

Yes, this skill performs all merge operations within a dedicated worktree to prevent interference with the main repository. The worktree and temporary branches are automatically removed after a successful merge.

Does the automated merge process handle post-merge branch cleanup?

Yes, the automated merge process handles post-merge cleanup by removing the dedicated worktree and temporary branches only after the squash merge is successfully completed.

What happens if my GitHub PR fails required checks before merging?

If required GitHub Actions checks fail or the PR is not in a mergeable state, the squash merge will not proceed. The skill validates these pre-merge conditions to ensure the branch is safe to integrate.