Skip to content

Instantly share code, notes, and snippets.

Created April 2, 2012 21:51
Show Gist options
  • Save anonymous/2287490 to your computer and use it in GitHub Desktop.
Save anonymous/2287490 to your computer and use it in GitHub Desktop.
Git grep + blame bash function
# runs git grep on a pattern, and then uses git blame to who did it
ggb() {
git grep -n $1 | while IFS=: read i j k; do git blame -L $j,$j $i | cat; done
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment