Skip to content

andrejsstepanovs/git-squash

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

14 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

git-squash

A simple CLI tool to squash multiple Git commits into a single commit.

Demo

git-squash demo

Installation

Download pre-compiled binary or

Install with go

go install github.com/andrejsstepanovs/git-squash@latest

Usage

# Interactive mode
git-squash

# Specify commit hash and message directly
git-squash -a <commit-hash> -m "New squashed commit message"

Options:

  • -a, --hash – Optional commit hash to squash from
  • -m, --message – Optional commit message for the squashed commit
  • --max – Auto-select the oldest selectable commit

How it works

  1. Lists squashable commits (not pushed yet).
  2. Lets you select the starting commit interactively (or via --hash).
  3. Performs a git reset --soft and commits the changes with your message.

About

cli tool that simplifies local git commit squashing

Resources

License

Stars

Watchers

Forks

Packages

No packages published