{"thread":{"id":"15721","subject":"Git config not expanding user home directories","startedAt":"2008-09-30T10:46:06Z","lastAt":"2008-10-01T07:52:36Z","messageCount":5,"participants":["Tom Lanyon","Andreas Ericsson","Jakub Narebski","Jeff King"],"isPatch":false,"patchVersion":null,"patchTotal":null},"messages":[{"id":"91921","messageId":"F90667E7-6B06-4B34-B655-3C42ED236D9A@netspot.com.au","threadId":"15721","inReplyTo":null,"subject":"Git config not expanding user home directories","fromName":"Tom Lanyon","fromEmail":"tom@netspot.com.au","sentAt":"2008-09-30T10:46:06Z","receivedAt":"2008-09-30T10:46:06Z","isPatch":false,"sender":{"key":"tom@netspot.com.au","avatar":null},"body":"Hi all,\n\nIs it normal behavior that git (well at least git-svn) won't expand  \n~user from .gitconfig?\n\nI was trying to set the svn.authorsfile config key to  \n~tom/.gitauthors; I received an error until changing it to read /home/ \ntom/.gitauthors.\n\nRegards,\nTom\n"},{"id":"91922","messageId":"48E2043A.4000501@op5.se","threadId":"15721","inReplyTo":"F90667E7-6B06-4B34-B655-3C42ED236D9A@netspot.com.au","subject":"Re: Git config not expanding user home directories","fromName":"Andreas Ericsson","fromEmail":"ae@op5.se","sentAt":"2008-09-30T10:49:30Z","receivedAt":"2008-09-30T10:49:30Z","isPatch":false,"sender":{"key":"ae@op5.se","avatar":"https://gravatar.com/avatar/426e89595c75a8f5252dd0c989e5fabe5bcac616e68557427ad9aef6b0ca342a?d=mp&s=160"},"body":"Tom Lanyon wrote:\n> Hi all,\n> \n> Is it normal behavior that git (well at least git-svn) won't expand \n> ~user from .gitconfig?\n> \n\nYes. You could add a patch for that though. git-daemon does ~user\nexpansion since quite a long time back, so there's a function ready\nfor it. I'd do it by doing something like:\n\n   git config --path section.key\n\nso that scripts can get the user-expanded version as well. In-core\napplications can call expand_path() or some such on their own, I\nthink.\n\n-- \nAndreas Ericsson                   andreas.ericsson@op5.se\nOP5 AB                             www.op5.se\nTel: +46 8-230225                  Fax: +46 8-230231\n"},{"id":"91931","messageId":"m33ajhsw24.fsf@localhost.localdomain","threadId":"15721","inReplyTo":"48E2043A.4000501@op5.se","subject":"Re: Git config not expanding user home directories","fromName":"Jakub Narebski","fromEmail":"jnareb@gmail.com","sentAt":"2008-09-30T11:38:46Z","receivedAt":"2008-09-30T11:38:46Z","isPatch":false,"sender":{"key":"jnareb@gmail.com","avatar":"https://avatars.githubusercontent.com/u/2706?v=4"},"body":"Andreas Ericsson <ae@op5.se> writes:\n\n> Tom Lanyon wrote:\n> > \n> > Is it normal behavior that git (well at least git-svn) won't expand\n> > ~user from .gitconfig?\n> >\n> \n> Yes. You could add a patch for that though. git-daemon does ~user\n> expansion since quite a long time back, so there's a function ready\n> for it. I'd do it by doing something like:\n> \n>    git config --path section.key\n> \n> so that scripts can get the user-expanded version as well. In-core\n> applications can call expand_path() or some such on their own, I\n> think.\n\nThere was a patch send to git mailing list adding basic '~' support\n(I think via $ENV{HOME}), and IIRC even ~user support. I don't know\nwhat happened to those patches (check mailing list archive), but\nmost probably it was not accepted because it didn't provide a way\nfor scripts to use this functionality, for example via --path option.\n\n-- \nJakub Narebski\nPoland\nShadeHawk on #git\n"},{"id":"92014","messageId":"20081001032246.GB24513@coredump.intra.peff.net","threadId":"15721","inReplyTo":"m33ajhsw24.fsf@localhost.localdomain","subject":"Re: Git config not expanding user home directories","fromName":"Jeff King","fromEmail":"peff@peff.net","sentAt":"2008-10-01T03:22:46Z","receivedAt":"2008-10-01T03:22:46Z","isPatch":false,"sender":{"key":"peff@peff.net","avatar":"https://avatars.githubusercontent.com/u/45925?v=4"},"body":"On Tue, Sep 30, 2008 at 04:38:46AM -0700, Jakub Narebski wrote:\n\n> There was a patch send to git mailing list adding basic '~' support\n> (I think via $ENV{HOME}), and IIRC even ~user support. I don't know\n> what happened to those patches (check mailing list archive), but\n> most probably it was not accepted because it didn't provide a way\n> for scripts to use this functionality, for example via --path option.\n\nThere were several rounds, and I thought it was shaping up, but then\nno more rounds came. I assume that Karl lost interest (or perhaps we\nnitpicked him to death), but I thought at the end of the thread Junio\nlaid out a plan for the next revision. I guess nobody cared enough about\nthe feature to implement it after that (though I think I found the final\nversion acceptable with a minor documentation tweak, I think Junio laid\nout a cleaner approach).\n\nThe last patch is here, with one of the replies from Junio giving the\naforementioned plan:\n\n  http://mid.gmane.org/quack.20080829T0229.lthhc94rwyr_-_@roar.cs.berkeley.edu\n\n-Peff\n"},{"id":"92037","messageId":"48E32C44.40708@op5.se","threadId":"15721","inReplyTo":"20081001032246.GB24513@coredump.intra.peff.net","subject":"Re: Git config not expanding user home directories","fromName":"Andreas Ericsson","fromEmail":"ae@op5.se","sentAt":"2008-10-01T07:52:36Z","receivedAt":"2008-10-01T07:52:36Z","isPatch":false,"sender":{"key":"ae@op5.se","avatar":"https://gravatar.com/avatar/426e89595c75a8f5252dd0c989e5fabe5bcac616e68557427ad9aef6b0ca342a?d=mp&s=160"},"body":"Jeff King wrote:\n> On Tue, Sep 30, 2008 at 04:38:46AM -0700, Jakub Narebski wrote:\n> \n>> There was a patch send to git mailing list adding basic '~' support\n>> (I think via $ENV{HOME}), and IIRC even ~user support. I don't know\n>> what happened to those patches (check mailing list archive), but\n>> most probably it was not accepted because it didn't provide a way\n>> for scripts to use this functionality, for example via --path option.\n> \n> There were several rounds, and I thought it was shaping up, but then\n> no more rounds came. I assume that Karl lost interest (or perhaps we\n> nitpicked him to death), but I thought at the end of the thread Junio\n> laid out a plan for the next revision. I guess nobody cared enough about\n> the feature to implement it after that (though I think I found the final\n> version acceptable with a minor documentation tweak, I think Junio laid\n> out a cleaner approach).\n> \n> The last patch is here, with one of the replies from Junio giving the\n> aforementioned plan:\n> \n>   http://mid.gmane.org/quack.20080829T0229.lthhc94rwyr_-_@roar.cs.berkeley.edu\n> \n\nThat looks roughly like the way I'd have done it. I'll see if I can find\nthe time to polish it up a bit.\n\n-- \nAndreas Ericsson                   andreas.ericsson@op5.se\nOP5 AB                             www.op5.se\nTel: +46 8-230225                  Fax: +46 8-230231\n"}]}