Fix grep.zsh: grep on FreeBSD 10 does not have --exclude-dir option.

This commit is contained in:
Arnaud Gomes 2014-04-09 13:50:45 +02:00
commit 8904d44d8d

View file

@ -5,9 +5,12 @@
# avoid VCS folders # avoid VCS folders
GREP_OPTIONS= GREP_OPTIONS=
for PATTERN in .cvs .git .hg .svn; do if [ $(uname) != "FreeBSD" ]
GREP_OPTIONS+="--exclude-dir=$PATTERN " then
done for PATTERN in .cvs .git .hg .svn; do
GREP_OPTIONS+="--exclude-dir=$PATTERN "
done
fi
GREP_OPTIONS+="--color=auto" GREP_OPTIONS+="--color=auto"
export GREP_OPTIONS="$GREP_OPTIONS" export GREP_OPTIONS="$GREP_OPTIONS"
export GREP_COLOR='1;32' export GREP_COLOR='1;32'