robbyrussell/oh-my-zsh — pull request #2711 by labeneator (2014-04-10 10:43:30+00:00)
Title: Legacy grep breaks on --exclude-dir option

This patch matches enables --exclude-dir iff the grep version is less than 2.5.3.
Tested on RHEL5 and OSX mavericks.
RHEL 5
----------
```
➜ lib git:(master) grep --version
grep (GNU grep) 2.5.1

Copyright 1988, 1992-1999, 2000, 2001 Free Software Foundation, Inc.
This is free software; see the source for copying conditions. There is NO
warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.

➜ lib git:(master) grep --version | head -n 1 | egrep " [0-2]\.[0-5]\.[0-2]"
grep (GNU grep) 2.5.1
```

OSX
---------
```
% grep --version
grep (BSD grep) 2.5.1-FreeBSD

% grep --version | head -n 1 | egrep " [0-2]\.[0-5]\.[0-2]"
grep (BSD grep) 2.5.1-FreeBSD
```