Re: [PATCH 2/4] add -u: get rid of "treewideupdate" configuration

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Fri, Apr 08, 2011 at 03:22:20PM -0700, Junio C Hamano wrote:

> So let's step back a bit.
> 
> How about we'd just add ':/' to make it equally easy to switch between
> "local only" vs "tree-wide" in 1.7.6 release, and be done with it.  We
> don't change the default for any of the commands at all.

Yeah, I am beginning to think that is a sensible route. And it commits
us to nothing, so if we decide much later that a change of default is
sensible, that is still open to us.

> Since more than a year ago, I've been saying that the ideal is to make the
> default not matter:
> 
>   http://thread.gmane.org/gmane.comp.version-control.git/133570/focus=133683
> 
> If the default does not matter, why change it?  It just causes us more
> headaches for dubious gain, no?

I'm not sure how much you can achieve the "make it not matter". The
shorthands go a long way, but I still want git to read my mind about
which I wanted to use (and the closest approximation of that, from my
experience, would be a per-repo variable). However, having the
shorthands mean that we can try them out in the real world and revisit
the topic in a year if people still care.

> IIRC, I think the two reasons why we started discussing of "add -u" and
> friends were that (1) some commands default to whole-tree while others
> limit to $cwd --- inconsistency is bad; and (2) when the user wants to do
> a full tree "add -u", there is no way other than counting the current
> depth and typing "../" that many times.
> 
> But when we looked at the current set of commands that limit them to the $cwd,
> we found that "add -u" was the only one that may make sense to switch the
> default, meaning that the "consistency" was not something we would even
> want to shoot for.  For example, we want our "git grep -e pattern" to
> mimic "grep -r -e pattern .".

I am not sure of that. I thought there was interest in full-tree grep
(OK, _I_ had some interst in it).  But the same transition pain
arguments apply there, and we should be able to do "git grep pattern :/"
soon, right?

-Peff
--
To unsubscribe from this list: send the line "unsubscribe git" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html


[Index of Archives]     [Linux Kernel Development]     [Gcc Help]     [IETF Annouce]     [DCCP]     [Netdev]     [Networking]     [Security]     [V4L]     [Bugtraq]     [Yosemite]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Linux SCSI]     [Fedora Users]