GitHub PR Merge

Merges GitHub pull requests via CLI or MCP with selectable strategies and automated checks.

1|1|Updated Feb 21, 2026
One-click install
npx skills add https://github.com/dtsong/claude-code-windows-setup --skill github-pr-merge-dtsong
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: GitHub PR Merge
Source: https://github.com/dtsong/claude-code-windows-setup/tree/main/skills/github-workflow/skills/gh-pr-merge
Command: npx skills add https://github.com/dtsong/claude-code-windows-setup --skill github-pr-merge-dtsong

SYSTEM DOCUMENTATION & REQUIREMENTS

💡 This Skill includes scripts (resource) and references (resource) components.

What problem does it solve?

This Skill streamlines the process of merging pull requests by providing clear strategy selection and automating pre-merge checks and post-merge cleanup.

Core Features & Use Cases

  • Strategic Merging: Choose between squash, rebase, or standard merge strategies.
  • Automated Checks: Verifies CI status, approvals, and merge conflicts before merging.
  • Branch Management: Optionally deletes merged branches.
  • Use Case: When a feature branch is ready, use this skill to merge it into main using a squash strategy, ensuring a clean commit history.

Quick Start

Use the gh-pr-merge skill to merge the current pull request with a squash strategy.

Frequently Asked Questions about GitHub PR Merge

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

FAQPage Schema
How do I automate a GitHub pull request merge with pre-merge checks?

You can automate a GitHub pull request merge by using a workflow that verifies CI status, approvals, and conflict resolution before executing the merge command. This streamlines the process by automating pre-merge checks and post-merge cleanup.

What is the best way to merge a GitHub pull request using a squash strategy?

The best way to merge a pull request using a squash strategy is to use an automation tool that selects the squash merge option. This combines all commits into a single commit, ensuring a clean commit history on the main branch.

Can I automatically delete a branch after a GitHub pull request merges?

Yes, you can automatically delete a branch after a GitHub pull request merges by configuring branch management in your workflow. The automation handles post-merge branch deletion to keep the repository clean and organized.

Does the GitHub PR merge automation work with the GitHub CLI?

Yes, the GitHub PR merge automation integrates directly with the GitHub CLI and MCP. This integration provides robust workflow automation for executing merges and verifying repository status.

What is the difference between squash, rebase, and standard merge strategies for pull requests?

Squash merge combines all commits into one, rebase applies commits sequentially without a merge commit, and standard merge creates a merge commit. You can configure your pull request merge to use any of these strategies.

How do I check for merge conflicts before merging a GitHub pull request?

You can check for merge conflicts before merging a GitHub pull request by running automated pre-merge checks. These checks verify CI status, approvals, and conflict resolution to ensure the branch is ready for integration.