https://github.com/kiprasmel/git-rebase-diff
git range-diff, but works automatically after a rebase.
https://github.com/kiprasmel/git-rebase-diff
git range-diff rebase sanity-check
Last synced: about 1 year ago
JSON representation
git range-diff, but works automatically after a rebase.
- Host: GitHub
- URL: https://github.com/kiprasmel/git-rebase-diff
- Owner: kiprasmel
- Created: 2022-08-22T18:28:05.000Z (almost 4 years ago)
- Default Branch: master
- Last Pushed: 2024-03-19T21:16:21.000Z (about 2 years ago)
- Last Synced: 2025-03-26T16:38:51.095Z (about 1 year ago)
- Topics: git, range-diff, rebase, sanity-check
- Language: Shell
- Homepage:
- Size: 21.5 KB
- Stars: 6
- Watchers: 1
- Forks: 1
- Open Issues: 0
-
Metadata Files:
- Readme: README
Awesome Lists containing this project
README
git-rebase-diff
===============
a tiny wrapper around git range-diff,
to make it easy to use after performing a rebase.
esp useful if encountered merge conflicts
& want to verify that nothing screwed up.
see also: https://github.com/kiprasmel/git-diff3c
setup
-----
```
git clone https://github.com/kiprasmel/git-rebase-diff.git
# or: git clone git@github.com:kiprasmel/git-rebase-diff.git
cd git-rebase-diff
cp git-rebase-diff /usr/local/bin/
git config --global init.defaultBranch=master # or whatever branch you use as default
```
usage
-----
expects that you:
- are checked out in the branch you rebased.
- have *not* pushed the branch to the remote yet.
```
git-rebase-diff
git-rebase-diff [-r|--remote origin] [-p|--parent-branch master] [-d|--debug]
git-rebase-diff [-r|--remote origin] [-p|--parent-branch master] [-d|--debug] -- [range-diff args]...
```
environment variables
---------------------
configure the defaults via:
- GIT_REBASE_DIFF_DEFAULT_REMOTE
- GIT_REBASE_DIFF_DEFAULT_PARENT
git config
----------
respects:
- init.defaultBranch
see also
--------
- man git-range-diff
- https://github.com/kiprasmel/git-diff3c
---
update
------
i've been experimenting with revision syntax.
there's some work in the `experiment' branch; not ready yet.
in the meantime, one can try:
- git range-diff @{1}...
- to get the range diff of HEAD vs last version of HEAD
- use `@{n}' to get HEAD vs `n'th-previous version of HEAD
- git range-diff @{u}...
- to get the range diff of HEAD vs remote HEAD
- use `@{u}@{n}' to get HEAD vs `n'th-previous version of remote HEAD