Re: [PATCH 1/2] clone: respect the settings in $HOME/.gitconfig and /etc/gitconfig

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

 



On Sun, 29 Jun 2008, Johannes Schindelin wrote:

> Hi,
> 
> On Sun, 29 Jun 2008, Daniel Barkalow wrote:
> 
> > Did we even make a commitment on whether:
> > 
> > GIT_CONFIG=foo git clone bar
> > 
> > must ignore the environment variable, or simply doesn't necessarily obey 
> > it?
> 
> I'd rather strongly argue that no matter what is the answer to this 
> question, we _HAVE TO_ unsetenv() GIT_CONFIG at some stage, otherwise no 
> .git/config will be written.

Why should .git/config get written? The user is explicitly using a 
different file instead, so .git/config really shouldn't get written, 
unless the user isn't allowed to use the environment variable or the 
environment variable shouldn't apply.

Actually, perhaps the right thing is to remove the code to look at the 
environment variable from config.c and have it in builtin-config.c, since 
only "git config" is actually documented to be affected by GIT_CONFIG at 
all. But I don't really know what the variable is supposed to do, beyond 
what's in the documentation. In any case, I don't think "git clone" is at 
all special with respect to GIT_CONFIG.

	-Daniel
*This .sig left intentionally blank*
--
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]

  Powered by Linux