-
-
Save ezza/7425563 to your computer and use it in GitHub Desktop.
Add to bashrc so you can stashgrep term
This file contains 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
# added to ~/.bashrc | |
stashgrep() { | |
for i in `git stash list --format="%gd"`; do | |
git stash show -p $i | grep -H --label="$i" "$1" | |
done | |
} | |
# usage: | |
# stashgrep zip | |
# returns | |
# stash@{1}: rubyzip (0.9.6.1) | |
# stash@{3}:+ def zip(filename, data) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment