* Git config not expanding user home directories
@ 2008-09-30 10:46 Tom Lanyon
2008-09-30 10:49 ` Andreas Ericsson
0 siblings, 1 reply; 5+ messages in thread
From: Tom Lanyon @ 2008-09-30 10:46 UTC (permalink / raw)
To: Git Mailinglist
Hi all,
Is it normal behavior that git (well at least git-svn) won't expand
~user from .gitconfig?
I was trying to set the svn.authorsfile config key to
~tom/.gitauthors; I received an error until changing it to read /home/
tom/.gitauthors.
Regards,
Tom
^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: Git config not expanding user home directories
2008-09-30 10:46 Git config not expanding user home directories Tom Lanyon
@ 2008-09-30 10:49 ` Andreas Ericsson
2008-09-30 11:38 ` Jakub Narebski
0 siblings, 1 reply; 5+ messages in thread
From: Andreas Ericsson @ 2008-09-30 10:49 UTC (permalink / raw)
To: Tom Lanyon; +Cc: Git Mailinglist
Tom Lanyon wrote:
> Hi all,
>
> Is it normal behavior that git (well at least git-svn) won't expand
> ~user from .gitconfig?
>
Yes. You could add a patch for that though. git-daemon does ~user
expansion since quite a long time back, so there's a function ready
for it. I'd do it by doing something like:
git config --path section.key
so that scripts can get the user-expanded version as well. In-core
applications can call expand_path() or some such on their own, I
think.
--
Andreas Ericsson andreas.ericsson@op5.se
OP5 AB www.op5.se
Tel: +46 8-230225 Fax: +46 8-230231
^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: Git config not expanding user home directories
2008-09-30 10:49 ` Andreas Ericsson
@ 2008-09-30 11:38 ` Jakub Narebski
2008-10-01 3:22 ` Jeff King
0 siblings, 1 reply; 5+ messages in thread
From: Jakub Narebski @ 2008-09-30 11:38 UTC (permalink / raw)
To: Andreas Ericsson; +Cc: Tom Lanyon, Git Mailinglist
Andreas Ericsson <ae@op5.se> writes:
> Tom Lanyon wrote:
> >
> > Is it normal behavior that git (well at least git-svn) won't expand
> > ~user from .gitconfig?
> >
>
> Yes. You could add a patch for that though. git-daemon does ~user
> expansion since quite a long time back, so there's a function ready
> for it. I'd do it by doing something like:
>
> git config --path section.key
>
> so that scripts can get the user-expanded version as well. In-core
> applications can call expand_path() or some such on their own, I
> think.
There was a patch send to git mailing list adding basic '~' support
(I think via $ENV{HOME}), and IIRC even ~user support. I don't know
what happened to those patches (check mailing list archive), but
most probably it was not accepted because it didn't provide a way
for scripts to use this functionality, for example via --path option.
--
Jakub Narebski
Poland
ShadeHawk on #git
^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: Git config not expanding user home directories
2008-09-30 11:38 ` Jakub Narebski
@ 2008-10-01 3:22 ` Jeff King
2008-10-01 7:52 ` Andreas Ericsson
0 siblings, 1 reply; 5+ messages in thread
From: Jeff King @ 2008-10-01 3:22 UTC (permalink / raw)
To: Jakub Narebski; +Cc: Andreas Ericsson, Tom Lanyon, Karl Chen, Git Mailinglist
On Tue, Sep 30, 2008 at 04:38:46AM -0700, Jakub Narebski wrote:
> There was a patch send to git mailing list adding basic '~' support
> (I think via $ENV{HOME}), and IIRC even ~user support. I don't know
> what happened to those patches (check mailing list archive), but
> most probably it was not accepted because it didn't provide a way
> for scripts to use this functionality, for example via --path option.
There were several rounds, and I thought it was shaping up, but then
no more rounds came. I assume that Karl lost interest (or perhaps we
nitpicked him to death), but I thought at the end of the thread Junio
laid out a plan for the next revision. I guess nobody cared enough about
the feature to implement it after that (though I think I found the final
version acceptable with a minor documentation tweak, I think Junio laid
out a cleaner approach).
The last patch is here, with one of the replies from Junio giving the
aforementioned plan:
http://mid.gmane.org/quack.20080829T0229.lthhc94rwyr_-_@roar.cs.berkeley.edu
-Peff
^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: Git config not expanding user home directories
2008-10-01 3:22 ` Jeff King
@ 2008-10-01 7:52 ` Andreas Ericsson
0 siblings, 0 replies; 5+ messages in thread
From: Andreas Ericsson @ 2008-10-01 7:52 UTC (permalink / raw)
To: Jeff King; +Cc: Jakub Narebski, Tom Lanyon, Karl Chen, Git Mailinglist
Jeff King wrote:
> On Tue, Sep 30, 2008 at 04:38:46AM -0700, Jakub Narebski wrote:
>
>> There was a patch send to git mailing list adding basic '~' support
>> (I think via $ENV{HOME}), and IIRC even ~user support. I don't know
>> what happened to those patches (check mailing list archive), but
>> most probably it was not accepted because it didn't provide a way
>> for scripts to use this functionality, for example via --path option.
>
> There were several rounds, and I thought it was shaping up, but then
> no more rounds came. I assume that Karl lost interest (or perhaps we
> nitpicked him to death), but I thought at the end of the thread Junio
> laid out a plan for the next revision. I guess nobody cared enough about
> the feature to implement it after that (though I think I found the final
> version acceptable with a minor documentation tweak, I think Junio laid
> out a cleaner approach).
>
> The last patch is here, with one of the replies from Junio giving the
> aforementioned plan:
>
> http://mid.gmane.org/quack.20080829T0229.lthhc94rwyr_-_@roar.cs.berkeley.edu
>
That looks roughly like the way I'd have done it. I'll see if I can find
the time to polish it up a bit.
--
Andreas Ericsson andreas.ericsson@op5.se
OP5 AB www.op5.se
Tel: +46 8-230225 Fax: +46 8-230231
^ permalink raw reply [flat|nested] 5+ messages in thread
end of thread, other threads:[~2008-10-01 7:54 UTC | newest]
Thread overview: 5+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2008-09-30 10:46 Git config not expanding user home directories Tom Lanyon
2008-09-30 10:49 ` Andreas Ericsson
2008-09-30 11:38 ` Jakub Narebski
2008-10-01 3:22 ` Jeff King
2008-10-01 7:52 ` Andreas Ericsson
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).