GREP_OPTIONS='-RI --color=auto'. Or install ack.
Obviously I want to search subdirectories. I can choose between
-R, or using
rgrep on this particular machine.
I am usually searching through source code. I hardly ever want
binary files to match. That means
Finally, I like pretty colors. The
--color=auto option makes me
That leaves me with this invocation.
$ grep --recursive --binary-file=without-match --color=auto 'TODO' .
Or maybe the short form would be easier.
$ rgrep -I --color=auto 'TODO' .
Probably smartest to look at what environment variables I could set up in order to skip remembering this stuff at all.
export GREP_OPTIONS='-RI --color=auto'
Pop that in my
.bashrc and I'm set.
$ grep 'TODO' .
All right. Back to work.