git-squash-merge

Consolidate unmerged changes into a single commit via squash merge.

1|Updated Mar 14, 2026
One-click install
npx skills add https://github.com/RussBrown00/agent-skills --skill git-squash-merge
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: git-squash-merge
Source: https://github.com/RussBrown00/agent-skills/tree/main/git-squash-merge
Command: npx skills add https://github.com/RussBrown00/agent-skills --skill git-squash-merge

SYSTEM DOCUMENTATION & REQUIREMENTS

What problem does it solve?

This workflow consolidates all changes since a specified target commit into a single, clean commit. It commits any pending work, resets to the target hash, performs a squash merge, and generates a final, polished commit message from the intervening history.

Core Features & Use Cases

  • Commit pending work so no changes are lost before squashing.
  • Reset to a defined target commit and squash all interim commits into one.
  • Generate a clear, conventional-style commit message from the history for a clean project tree.
  • Use when you need to present a simplified, reviewable history for releases or integration.

Quick Start

Tell your AI assistant to squash all changes to the target commit hash using the described workflow.

Frequently Asked Questions about git-squash-merge

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

FAQPage Schema
How do I consolidate feature branch commits into a single clean commit?

To consolidate feature branch commits into a single clean commit, the workflow commits pending work, resets to a target hash, and performs a squash merge with a generated conventional-style message.

What is the best way to generate a commit message from squashed git history?

Generating a commit message from squashed git history is handled by a helper that formats the intervening commit log into a clear, conventional-style message, ensuring a clean and reviewable project tree for releases.

Does squashing commits in git lose uncommitted work?

Squashing commits in git does not lose uncommitted work because the workflow commits pending changes before resetting to the target commit and performing the squash merge.

When should I use a squash merge for my version control workflow?

You should use a squash merge in your version control workflow when integrating changes from a feature branch and needing to present a simplified, clean commit history for releases or final review.

Are destructive git resets performed automatically during a squash merge?

Destructive git resets are not performed automatically; they are only executed when explicitly requested by the user, with deterministic steps and safety checks applied throughout the workflow.