Skip to content

Commit 552c9be

Browse files
committed
Create git alias for comparing branches
Signed-off-by: Merlin Rabens <m.rabens@hotmail.de>
1 parent 83ff038 commit 552c9be

1 file changed

Lines changed: 4 additions & 0 deletions

File tree

.gitconfig

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -82,6 +82,10 @@
8282
fi \
8383
}; f"
8484
85+
# Compare two branches and show which commits are not in the first
86+
# but in the second branch
87+
compare = "!f() { git log --graph --pretty=format:'%Cred%h%Creset -%C(yellow)%d%Creset %s %Cgreen(%cr)%Creset' --abbrev-commit --date=relative $1..$2; }; f"
88+
8589
[apply]
8690
8791
# Detect whitespace errors when applying a patch

0 commit comments

Comments
 (0)