git-squash

Community

Consolidate Git commits safely, simplify history.

Authorcowwoc
Version1.0.0
Installs0

System Documentation

What problem does it solve?

A feature branch often accumulates many small, iterative commits that clutter the Git history. Squashing these into a single, meaningful commit is crucial for a clean main branch, but carries the significant risk of data loss or unintended changes if not executed with extreme precision. This Skill provides a robust, verified process to simplify your history.

Core Features & Use Cases

  • Mandatory Backup & Rollback: Creates a timestamped backup branch before any squash operation and provides clear rollback instructions, ensuring data safety and peace of mind.
  • Precise Commit Selection: Guides the user to correctly position HEAD and verifies the exact range of commits to be squashed, preventing accidental over-squashing (a common mistake).
  • Comprehensive Verification: Performs multiple checks (staged changes vs. original, non-squashed commits unchanged, final working tree state) to guarantee no changes are lost or added.
  • Use Case: You've made several commits while developing a new feature, and now you want to combine them into one clean commit before creating a pull request. This Skill ensures that only the intended commits are squashed, no code is lost, and the history remains pristine, all with safety checks at every step, so "AI works, you rest."

Quick Start

Use the git-squash skill to combine the last 3 commits on the current branch into a single commit.

Dependency Matrix

Required Modules

git

Components

Standard package

💻 Claude Code Installation

Recommended: Let Claude install automatically. Simply copy and paste the text below to Claude Code.

Please help me install this Skill:
Name: git-squash
Download link: https://github.com/cowwoc/styler/archive/main.zip#git-squash

Please download this .zip file, extract it, and install it in the .claude/skills/ directory.
View Source Repository