update-after-merge

Switch to the default branch, pull updates, and delete merged feature branches.

2|5|Updated Jan 2, 2026
One-click install
npx skills add https://github.com/whoabuddy/claude-knowledge --skill update-after-merge
Or copy as Structured Prompt for Agent▼
Please help me install this Agent Skill.
Skill: update-after-merge
Source: https://github.com/whoabuddy/claude-knowledge/tree/main/claude-config/skills/update-after-merge
Command: npx skills add https://github.com/whoabuddy/claude-knowledge --skill update-after-merge

SYSTEM DOCUMENTATION & REQUIREMENTS

What problem does it solve?

Clean up local repository state after a PR merge by switching to the default branch, pulling latest changes, and removing the feature branch locally and remotely when appropriate.

Core Features & Use Cases

  • Switches to the default branch (main or master) after a merge.
  • Updates the local copy of the default branch and prunes stale branches.
  • Deletes merged feature branches locally and optionally on the remote.

Quick Start

Run /update-after-merge to clean up your current feature branch or specify a branch name to clean up a specific branch.

Frequently Asked Questions about update-after-merge

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

FAQPage Schema
How do I clean up local git branches after a PR merge?▼

To clean up local git branches after a merge, switch to the default branch, pull the latest changes, and delete the merged feature branch locally and remotely. This automates post-merge repository hygiene safely.

What is the best way to automate git branch deletion and default branch updates?▼

Automating git branch deletion involves switching to the default branch, pulling updates, and pruning stale remote branches. This process ensures consistent post-merge cleanup across both single-repo and multi-repo workflows.

Can I safely delete a feature branch with uncommitted changes?▼

Yes, safe feature branch deletion with uncommitted changes requires stashing modifications first. The workflow enforces this safety step before switching to the default branch and pulling updates.

Does post-merge cleanup work with multi-repo development workflows?▼

Post-merge cleanup applies across both single-repo and multi-repo development workflows. It ensures consistent repository hygiene by switching branches, pulling updates, and safely deleting merged local and remote branches.

How do I prune stale remote branches after merging a pull request?▼

Pruning stale remote branches after a pull request merge is handled by switching to the default branch and pulling updates. The process optionally removes the feature branch on the remote when appropriate.