From: Mike Frysinger Date: Thu, 22 Mar 2012 15:45:55 +0000 (-0400) Subject: update grep/scrub_patch X-Git-Url: https://git.wh0rd.org/?a=commitdiff_plain;h=4c1fde46237f3b9a662ce17049a5cde30cf37b95;p=home.git update grep/scrub_patch --- diff --git a/.profile.d/aliases.sh b/.profile.d/aliases.sh index 2b6f317..98bf762 100644 --- a/.profile.d/aliases.sh +++ b/.profile.d/aliases.sh @@ -32,17 +32,17 @@ alias xine='xine -l' alias wol-vapier='wakeonlan -i 192.168.1.255 00:25:22:64:19:79; wakeonlan -i 192.168.0.255 00:25:22:64:19:79' if [[ ${TERM} != "dumb" ]] ; then - alias grep='grep --colour=auto' + alias grep='grep --colour=auto -d skip' alias ls='ls --color=auto' fi grep-svn() { find '(' -wholename '*/.svn' -prune -o -type f -print0 ')' | xargs -0 grep "$@" ; } scrub_patch() { - sed -i \ - -e '/^index /d' \ + sed -i \ + -e '/^index /d' \ -e '/^new file mode /d' \ - -e '/^Index:/d' \ + -e '/^Index:/d' \ -e '/^=========/d' \ -e '/^RCS file:/d' \ -e '/^retrieving/d' \ @@ -50,9 +50,10 @@ scrub_patch() { -e '/^Files .* differ$/d' \ -e '/^Only in /d' \ -e '/^Common subdirectories/d' \ - -e '/^+++/s:\t.*::' \ - -e '/^---/s:\t.*::' \ - "$@" + -e '/^deleted file mode [0-9]*$/d' \ + -e '/^+++/s:\t.*::' \ + -e '/^---/s:\t.*::' \ + "$@" } scrub_html() {