Re: [PATCH] grep: --full-tree
From: Johannes Schindelin <hidden>
Date: 2016-06-15 22:47:46
Hi, On Wed, 25 Nov 2009, Junio C Hamano wrote:
Jeff King [off-list ref] writes:quoted
On Wed, Nov 25, 2009 at 12:52:11PM -0800, Junio C Hamano wrote:quoted
So I think the posted patch alone without changing anything else would be the approach to give the most benefit with the least impact to existing users, at least for now.Yes, I meant to say in my original message but forgot to: I think --full-tree is an important first step, no matter what happens next. It gives people a way to do what they want without typing the right number of ".."s, and it opens up --no-full-tree if the default changes later. But I do worry about it being a command-line option. You are asking the user to remember to type --full-tree every time.We could redefine get_pathspec() to treat a pathspec that begins with a slash to be anchored at the top,
This would break spectacularly in MSys. And this is just one reason not to do this "magic". Clearly, a command line option is the only unambiguous way to do what you want to do (and not changing the default all of a sudden). Ciao, Dscho