Re: [PATCH 2/2] Revert "rev-parse: remove restrictions on some options"

2016-02-29 Thread Jeff King
On Mon, Feb 29, 2016 at 09:32:22AM -0800, Junio C Hamano wrote: > Jeff King writes: > > > IOW, I think my 2/2 should be replaced with this: > > This looks sensible. > > Don't we still want the documentation updates from the previous 2/2? I don't think so. They were primarily about moving thos

Re: [PATCH 2/2] Revert "rev-parse: remove restrictions on some options"

2016-02-29 Thread Junio C Hamano
Jeff King writes: > IOW, I think my 2/2 should be replaced with this: This looks sensible. Don't we still want the documentation updates from the previous 2/2? -- To unsubscribe from this list: send the line "unsubscribe git" in the body of a message to majord...@vger.kernel.org More majordomo

Re: [PATCH 2/2] Revert "rev-parse: remove restrictions on some options"

2016-02-29 Thread Jeff King
On Sat, Feb 27, 2016 at 07:53:02PM -0500, Eric Sunshine wrote: > > then it must receive the two lines of output in the correct > > s/correct/& order/ I fixed this and all of the other typos by switching to a patch that needs about one tenth as much explanation. :) I'm sure it's not possible tha

Re: [PATCH 2/2] Revert "rev-parse: remove restrictions on some options"

2016-02-29 Thread Jeff King
On Sat, Feb 27, 2016 at 12:25:11PM +, John Keeping wrote: > On Fri, Feb 26, 2016 at 06:29:57PM -0500, Jeff King wrote: > > This reverts commit 68889b416d5b6a5cf7d280a428281d635fe9b292. > [snip] > > The original patch was not spurred by an actual bug report, > > but by an observation[1] that wa

Re: [PATCH 2/2] Revert "rev-parse: remove restrictions on some options"

2016-02-29 Thread Jeff King
On Fri, Feb 26, 2016 at 06:34:49PM -0500, Jeff King wrote: > > So any implementation would probably have to either: > > > > - make two passes over the options, first figuring out > > whether we need a git-dir, and then actually handling > > the options. That's possible, but it's probabl

Re: [PATCH 2/2] Revert "rev-parse: remove restrictions on some options"

2016-02-27 Thread Eric Sunshine
On Fri, Feb 26, 2016 at 6:29 PM, Jeff King wrote: > This reverts commit 68889b416d5b6a5cf7d280a428281d635fe9b292. > > That commit bumped some rev-parse options into the main > option-parsing loop, which meant that they no longer had to > come at the very beginning of the option list. However, that

Re: [PATCH 2/2] Revert "rev-parse: remove restrictions on some options"

2016-02-27 Thread John Keeping
On Fri, Feb 26, 2016 at 06:29:57PM -0500, Jeff King wrote: > This reverts commit 68889b416d5b6a5cf7d280a428281d635fe9b292. [snip] > The original patch was not spurred by an actual bug report, > but by an observation[1] that was essentially "eh, this > looks unnecessarily restrictive". It _is_ restr

Re: [PATCH 2/2] Revert "rev-parse: remove restrictions on some options"

2016-02-26 Thread Jeff King
On Fri, Feb 26, 2016 at 03:44:01PM -0800, Junio C Hamano wrote: > But why do you even need to run local-env-vars from outside a > repository in the first place? The short answer is: because it is about clearing the state to move into a new repository, and we do not necessarily know what the old s

Re: [PATCH 2/2] Revert "rev-parse: remove restrictions on some options"

2016-02-26 Thread Junio C Hamano
Jeff King writes: > On Fri, Feb 26, 2016 at 06:29:57PM -0500, Jeff King wrote: > >> The best solution here would be to have a full parsing loop >> that handles all options, but only calls setup_git_directory >> as appropriate. Unfortunately, that's a bit complicated to >> implement. We _have_ to

Re: [PATCH 2/2] Revert "rev-parse: remove restrictions on some options"

2016-02-26 Thread Jeff King
On Fri, Feb 26, 2016 at 06:29:57PM -0500, Jeff King wrote: > The best solution here would be to have a full parsing loop > that handles all options, but only calls setup_git_directory > as appropriate. Unfortunately, that's a bit complicated to > implement. We _have_ to handle each option in the o

[PATCH 2/2] Revert "rev-parse: remove restrictions on some options"

2016-02-26 Thread Jeff King
This reverts commit 68889b416d5b6a5cf7d280a428281d635fe9b292. That commit bumped some rev-parse options into the main option-parsing loop, which meant that they no longer had to come at the very beginning of the option list. However, that also means that they now came after our call to setup_git_d