On Tue, Jul 20, 2010 at 9:38 PM, David Korn <[email protected]> wrote: > Subject: Re: [ast-developers] Feature request: AST grep -r > -------- > > >> I like to request that AST grep gets GNU grep's option -r to >> recursively search a directory tree. IMO AST grep is superior to GNU >> grep but the lack of easy search with GNU grep -r forces me to pick >> GNU grep on such occasion :( >> >> Chris >> > > Did you consider using > tw grep > for this? > > Another alternative with ksh93 is to use > set -o globstar > alias grep='command -x grep' > grep pattern **/*
We've been there half a year ago and I wrote as reply: I agree with you that grep -r is an abomination. I would even agree that we should take a time machine, travel back to 1996, hijack the GNU hacker who invented -r, paint "I am a spy from Iran" on his forehead and send him straight to Saddam Hussein. Unfortunately time machines do not exist yet and many of the simple, sporadic UNIX users all know about grep -r. I verified this, I went to the cafeteria this morning and asked 5 random people from engineering how they search a tree of text files on UNIX. They all *prefer* grep -r. I think the ship has sailed and while grep -r is bad from a design standpoint it's now common usage. I'd say: Please add -r to grep to make the users happy. Even if it's dumb from the powerusers viewpoint. Irek _______________________________________________ ast-developers mailing list [email protected] https://mailman.research.att.com/mailman/listinfo/ast-developers
