Skip to content

Instantly share code, notes, and snippets.

@chrisdarroch
chrisdarroch / .bashrc
Last active December 20, 2016 16:29
A shell function that shows you the difference a Git branch made at the point it branched from your current one
function gdist {
basename="$1"
basesha="git merge-base HEAD $basename"
git diff "$basesha" "$basename"
}