Re: [PATCH] sequencer: pass absolute GIT_WORK_TREE to exec commands

2018-07-14 Thread brian m. carlson
On Sat, Jul 14, 2018 at 11:05:34PM +0200, Johannes Schindelin wrote: > Hi Brian, > > On Sat, 14 Jul 2018, brian m. carlson wrote: > > Dscho, is this test going to cause a problem on Windows with the forward > > slash in the grep statement? > > It passes on Windows. The reason is that you are

Re: [PATCH] sequencer: pass absolute GIT_WORK_TREE to exec commands

2018-07-14 Thread Johannes Schindelin
Hi Brian, On Sat, 14 Jul 2018, brian m. carlson wrote: > The sequencer currently passes GIT_DIR, but not GIT_WORK_TREE, to exec > commands. In that configuration, we assume that whatever directory > we're in is the top level of the work tree, and git rev-parse > --show-toplevel responds

Re: [PATCH] sequencer: pass absolute GIT_WORK_TREE to exec commands

2018-07-14 Thread brian m. carlson
On Fri, Jul 13, 2018 at 08:57:03PM -0400, Jeff King wrote: > On Sat, Jul 14, 2018 at 12:35:05AM +, brian m. carlson wrote: > > > diff --git a/sequencer.c b/sequencer.c > > index 5354d4d51e..c8e16f9168 100644 > > --- a/sequencer.c > > +++ b/sequencer.c > > @@ -2636,6 +2636,8 @@ static int

Re: [PATCH] sequencer: pass absolute GIT_WORK_TREE to exec commands

2018-07-13 Thread Jeff King
On Sat, Jul 14, 2018 at 12:35:05AM +, brian m. carlson wrote: > diff --git a/sequencer.c b/sequencer.c > index 5354d4d51e..c8e16f9168 100644 > --- a/sequencer.c > +++ b/sequencer.c > @@ -2636,6 +2636,8 @@ static int do_exec(const char *command_line) > fprintf(stderr, "Executing: %s\n",

[PATCH] sequencer: pass absolute GIT_WORK_TREE to exec commands

2018-07-13 Thread brian m. carlson
The sequencer currently passes GIT_DIR, but not GIT_WORK_TREE, to exec commands. In that configuration, we assume that whatever directory we're in is the top level of the work tree, and git rev-parse --show-toplevel responds accordingly. However, when we're in a subdirectory, that isn't correct: