Skip to content

Instantly share code, notes, and snippets.

Embed
What would you like to do?
Bash function to exclude files named *.info from a git diff.
git-diff-no-info ()
{
git diff `git status -s | grep -v ^\ D | grep -v info$ | cut -b4-`
}
@chx

This comment has been minimized.

Copy link

@chx chx commented Feb 24, 2016

git diff `git diff HEAD --name-only --pretty="format:"|grep -v \.info$`
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment