{"thread":{"id":"48780","subject":"curious about wording in \"man git-config\", ENVIRONMENT","startedAt":"2018-06-26T10:18:32Z","lastAt":"2018-06-28T18:17:57Z","messageCount":4,"participants":["Robert P. J. Day","Jeff King"],"isPatch":false,"patchVersion":null,"patchTotal":null},"messages":[{"id":"350955","messageId":"alpine.LFD.2.21.1806260608270.6007@localhost.localdomain","threadId":"48780","inReplyTo":null,"subject":"curious about wording in \"man git-config\", ENVIRONMENT","fromName":"Robert P. J. Day","fromEmail":"rpjday@crashcourse.ca","sentAt":"2018-06-26T10:18:26Z","receivedAt":"2018-06-26T10:18:32Z","isPatch":false,"sender":{"key":"rpjday@crashcourse.ca","avatar":"https://avatars.githubusercontent.com/u/226084077?v=4"},"body":"\n  ENVIRONMENT\n    GIT_CONFIG\n      Take the configuration from the given file instead of\n      .git/config. Using the \"--global\" option forces this to\n      ~/.gitconfig. Using the \"--system\" option forces this to\n      $(prefix)/etc/gitconfig.\n\n  is the phrase \"forces this to\" really what you want to use here?\nmaybe i misunderstand what this option does, doesn't it simply mean\nthat it will use a different (specified) file from the default,\ndepending on the context (local, global, system)?\n\n  it just seems weird to say that the option \"forces\" the use of what\nare clearly the default files. thoughts?\n\nrday\n\n-- \n\n========================================================================\nRobert P. J. Day                                 Ottawa, Ontario, CANADA\n                  http://crashcourse.ca/dokuwiki\n\nTwitter:                                       http://twitter.com/rpjday\nLinkedIn:                               http://ca.linkedin.com/in/rpjday\n========================================================================\n"},{"id":"350966","messageId":"20180626124316.GA15419@sigill.intra.peff.net","threadId":"48780","inReplyTo":"alpine.LFD.2.21.1806260608270.6007@localhost.localdomain","subject":"Re: curious about wording in \"man git-config\", ENVIRONMENT","fromName":"Jeff King","fromEmail":"peff@peff.net","sentAt":"2018-06-26T12:43:16Z","receivedAt":"2018-06-26T12:43:20Z","isPatch":false,"sender":{"key":"peff@peff.net","avatar":"https://avatars.githubusercontent.com/u/45925?v=4"},"body":"On Tue, Jun 26, 2018 at 06:18:26AM -0400, Robert P. J. Day wrote:\n\n> \n>   ENVIRONMENT\n>     GIT_CONFIG\n>       Take the configuration from the given file instead of\n>       .git/config. Using the \"--global\" option forces this to\n>       ~/.gitconfig. Using the \"--system\" option forces this to\n>       $(prefix)/etc/gitconfig.\n> \n>   is the phrase \"forces this to\" really what you want to use here?\n> maybe i misunderstand what this option does, doesn't it simply mean\n> that it will use a different (specified) file from the default,\n> depending on the context (local, global, system)?\n> \n>   it just seems weird to say that the option \"forces\" the use of what\n> are clearly the default files. thoughts?\n\nI agree it's weird. I think it's trying to mean \"behaves as if it was\nset to\", but with the additional notion that the command-line argument\nwould take precedence over the environment (which is our usual rule).\nBut then we should just say those things explicitly.\n\nJust looking at mentions of GIT_CONFIG in that manpage and knowing the\nhistory, I think:\n\n - the environment section should say something like:\n\n     GIT_CONFIG\n       If set and no other specific-file options are given, behaves as\n       if `--file=$GIT_CONFIG` was provided on the command-line.\n\n - possibly the manpage should mention that GIT_CONFIG is historical and\n   should not be used in new code (we could also consider an actual\n   deprecation period and removal of the feature, though aside from\n   documentation confusion I do not think it is hurting anyone)\n\n - the description of --file should not mention it at all. Instead it\n   should reference the \"FILES\" section which describes the whole lookup\n   sequence\n\n - mention of GIT_CONFIG should be dropped from the FILES section. We\n   don't want to point people towards using it. And if they come across\n   it in the wild, they can find it in the ENVIRONMENT section.\n\n - references to \"--global\" should stop mentioning ~/.gitconfig,\n   since in a post-XDG world it could be elsewhere (they're better to\n   refer to the \"--global\" description or the FILES section)\n\n - references to \"--system\" should stop mentioning $(prefix)/etc/gitconfig,\n   since it can be configured separately from the prefix (and in most\n   packaged builds which set prefix=/usr, $(sysconfdir) is not\n   $(prefix)/etc).\n\n-Peff\n"},{"id":"350980","messageId":"alpine.LFD.2.21.1806261250280.6102@localhost.localdomain","threadId":"48780","inReplyTo":"20180626124316.GA15419@sigill.intra.peff.net","subject":"Re: curious about wording in \"man git-config\", ENVIRONMENT","fromName":"Robert P. J. Day","fromEmail":"rpjday@crashcourse.ca","sentAt":"2018-06-26T16:51:45Z","receivedAt":"2018-06-26T16:51:54Z","isPatch":false,"sender":{"key":"rpjday@crashcourse.ca","avatar":"https://avatars.githubusercontent.com/u/226084077?v=4"},"body":"On Tue, 26 Jun 2018, Jeff King wrote:\n\n> On Tue, Jun 26, 2018 at 06:18:26AM -0400, Robert P. J. Day wrote:\n>\n> >\n> >   ENVIRONMENT\n> >     GIT_CONFIG\n> >       Take the configuration from the given file instead of\n> >       .git/config. Using the \"--global\" option forces this to\n> >       ~/.gitconfig. Using the \"--system\" option forces this to\n> >       $(prefix)/etc/gitconfig.\n> >\n> >   is the phrase \"forces this to\" really what you want to use here?\n> > maybe i misunderstand what this option does, doesn't it simply mean\n> > that it will use a different (specified) file from the default,\n> > depending on the context (local, global, system)?\n> >\n> >   it just seems weird to say that the option \"forces\" the use of what\n> > are clearly the default files. thoughts?\n>\n> I agree it's weird. I think it's trying to mean \"behaves as if it\n> was set to\", but with the additional notion that the command-line\n> argument would take precedence over the environment (which is our\n> usual rule). But then we should just say those things explicitly.\n>\n> Just looking at mentions of GIT_CONFIG in that manpage and knowing\n> the history, I think:\n\n  ... snip ...\n\ni'm just going to admit that i don't quite have the background to know\nhow to submit a patch to tidy things up based on Jeff's analysis, so\nI'm going to leave this to someone higher up the food chain.\n\nrday\n\n-- \n\n========================================================================\nRobert P. J. Day                                 Ottawa, Ontario, CANADA\n                  http://crashcourse.ca/dokuwiki\n\nTwitter:                                       http://twitter.com/rpjday\nLinkedIn:                               http://ca.linkedin.com/in/rpjday\n========================================================================\n"},{"id":"351252","messageId":"20180628181751.GA3693@sigill.intra.peff.net","threadId":"48780","inReplyTo":"alpine.LFD.2.21.1806261250280.6102@localhost.localdomain","subject":"Re: curious about wording in \"man git-config\", ENVIRONMENT","fromName":"Jeff King","fromEmail":"peff@peff.net","sentAt":"2018-06-28T18:17:51Z","receivedAt":"2018-06-28T18:17:57Z","isPatch":false,"sender":{"key":"peff@peff.net","avatar":"https://avatars.githubusercontent.com/u/45925?v=4"},"body":"On Tue, Jun 26, 2018 at 12:51:45PM -0400, Robert P. J. Day wrote:\n\n> > I agree it's weird. I think it's trying to mean \"behaves as if it\n> > was set to\", but with the additional notion that the command-line\n> > argument would take precedence over the environment (which is our\n> > usual rule). But then we should just say those things explicitly.\n> >\n> > Just looking at mentions of GIT_CONFIG in that manpage and knowing\n> > the history, I think:\n> \n>   ... snip ...\n> \n> i'm just going to admit that i don't quite have the background to know\n> how to submit a patch to tidy things up based on Jeff's analysis, so\n> I'm going to leave this to someone higher up the food chain.\n\nThere's some related discussion going on in:\n\n  https://public-inbox.org/git/20180627045637.13818-1-tmz@pobox.com/\n\nI think it makes sense to wait for that to settle and then I may try to\nbuild on top.\n\n-Peff\n"}]}