merge-pr

Squash-merge pull requests, delete remote and local branches, and pull main.

Updated Mar 9, 2026
One-click install
npx skills add https://github.com/poitch/skills --skill merge-pr-poitch
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: merge-pr
Source: https://github.com/poitch/skills/tree/main/merge-pr
Command: npx skills add https://github.com/poitch/skills --skill merge-pr-poitch

SYSTEM DOCUMENTATION & REQUIREMENTS

What problem does it solve?

This Skill automates the process of merging a pull request, cleaning up the associated branch, and returning you to the main development branch, streamlining your Git workflow.

Core Features & Use Cases

  • Automated Merging: Squash-merges pull requests, ensuring a clean commit history.
  • Branch Cleanup: Automatically deletes both the remote and local branches after a successful merge.
  • Workflow Reset: Switches your working directory back to the main branch and pulls the latest changes.
  • Use Case: After successfully reviewing and approving a pull request, you can invoke this skill to complete the merge process without manual Git commands.

Quick Start

Use the merge-pr skill to merge the current pull request.

Frequently Asked Questions about merge-pr

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

FAQPage Schema
How do I automatically merge a pull request and delete the branch in Git?

Merging a pull request and deleting the branch is automated by squash-merging the PR, removing both remote and local branches, and switching to main. This ensures a clean commit history and repository without manual Git commands.

Can I use this to squash merge a GitHub PR and pull the main branch?

Yes, you can squash merge a GitHub PR and pull the main branch using this automation. It executes a squash merge on the target pull request, removes the associated branches, and pulls the latest changes from main.

Do I need the gh and git CLI tools to automate pull request merging?

Yes, the gh and git CLI tools are required to automate pull request merging. This Skill relies on these command-line interfaces to perform the squash merge, branch deletion, and synchronization with the main branch.

What is the best way to clean up local and remote branches after a PR merge?

The best way to clean up local and remote branches after a PR merge is through automated deletion. This Skill removes both branches immediately following a successful squash merge and resets your working directory to main.

Does this branch management workflow work for individual developers and CI/CD pipelines?

Yes, this branch management workflow works for individual developers and CI/CD pipelines. It maintains a clean repository by automating the squash merge, branch deletion, and main branch synchronization across various development contexts.