Created
May 25, 2026 20:20
-
-
Save copyleftdev/7dc22db818f3f20e90bb117ad4e7e130 to your computer and use it in GitHub Desktop.
git range-diff — compare two sequences of commits patch by patch
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| # git range-diff — diff of diffs | |
| # Verify a rebase didn't silently mangle any patches. | |
| # Compare two parallel sequences of commits from a common base: | |
| git range-diff main@{1} main feature-branch | |
| # Output per commit pair: | |
| # 1: <sha1> = 1: <sha2> feat: add auth | |
| # 2: <sha1> ! 2: <sha2> feat: add routes ← ! means patches differ | |
| # | |
| # = means equivalent. ! opens the inner diff inline. | |
| # After a rebase — verify nothing drifted: | |
| git range-diff main@{1} main my-branch | |
| # Compare two branch sequences from a shared ancestor tag: | |
| git range-diff v1.0.0..polish/v1 v1.0.0..polish/v2 |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment