Re: [PATCH] rebase: exec leaks GIT_DIR to environment

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

 



On Sun, Oct 29, 2017 at 11:34 AM, Phillip Wood
<phillip.wood@xxxxxxxxxxxx> wrote:
>
> Just clearing GIT_DIR does not match the behavior of the shell version
> (tested by passing -p to avoid rebase--helper) as that passes GIT_DIR to
> exec commands if it has been explicitly set. I think that users that set
> GIT_DIR on the command line would expect it to be propagated to exec
> commands.
>
> $ git rebase -px'echo $GIT_DIR' @
>
>                                                             Merge commit
> '7c2f1abd64' into phil
> Executing: echo $GIT_DIR
>
> Successfully rebased and updated refs/heads/phil.
>
> $ env GIT_DIR=.git git rebase -px'echo $GIT_DIR' @
>
>                                                             Merge commit
> '7c2f1abd64' into phil
> Executing: echo $GIT_DIR
> /home/phil/Documents/src/git/.git/worktrees/git-next
> Successfully rebased and updated refs/heads/phil.
>

I'm not really sure what the exact fix is, since we do want to pass in
GIT_DIR if it was passed to us, but maybe it needs to be an absolute
path?

Thanks,
Jake



[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]

  Powered by Linux