{"thread":{"id":"9562","subject":"Can't figure out some sense from the git-commit-tree man page","startedAt":"2007-08-17T16:30:34Z","lastAt":"2007-08-17T23:51:01Z","messageCount":11,"participants":["Mike Hommey","Johannes Schindelin","J. Bruce Fields","Daniel Hulme","Jakub Narebski","Junio C Hamano"],"isPatch":false,"patchVersion":null,"patchTotal":null},"messages":[{"id":"50934","messageId":"20070817163034.GA11151@glandium.org","threadId":"9562","inReplyTo":null,"subject":"Can't figure out some sense from the git-commit-tree man page","fromName":"Mike Hommey","fromEmail":"mh@glandium.org","sentAt":"2007-08-17T16:30:34Z","receivedAt":"2007-08-17T16:30:34Z","isPatch":false,"sender":{"key":"mh@glandium.org","avatar":"https://avatars.githubusercontent.com/u/1038527?v=4"},"body":"Hi,\n\nThe git-commit-tree man page reads:\n  A commit encapsulates:\n\n  ·   all parent object ids\n\n  ·   author name, email and date\n\n  ·   committer name and email and the commit time.\n  If not provided, \"git-commit-tree\" uses your name, hostname and domain to\n  provide author and committer info. This can be overridden by either\n  .git/config file, or using the following environment variables.\n  (...)\n\nThe \"If not provided\" part doesn't make sense. If you're not setting the\nauthor and committer in your config or environment, how are you supposed\nto provide it ?\n\nNaively, I tried sending a \"git-cat-file commit\" looking text to stdin,\nbut it just ended up in the changelog, which was actually no surprise.\n\nMike\n"},{"id":"50935","messageId":"Pine.LNX.4.64.0708171751360.20400@racer.site","threadId":"9562","inReplyTo":"20070817163034.GA11151@glandium.org","subject":"Re: Can't figure out some sense from the git-commit-tree man page","fromName":"Johannes Schindelin","fromEmail":"johannes.schindelin@gmx.de","sentAt":"2007-08-17T16:52:52Z","receivedAt":"2007-08-17T16:52:52Z","isPatch":false,"sender":{"key":"johannes.schindelin@gmx.de","avatar":"https://avatars.githubusercontent.com/u/127790?v=4"},"body":"Hi,\n\nOn Fri, 17 Aug 2007, Mike Hommey wrote:\n\n>   ?   committer name and email and the commit time.\n>   If not provided, \"git-commit-tree\" uses your name, hostname and domain to\n>   provide author and committer info. This can be overridden by either\n>   .git/config file, or using the following environment variables.\n>   (...)\n> \n> The \"If not provided\" part doesn't make sense.\n\nIt does, if you know how to specify the committer info.  Which the man \npage specifies how to provide:\n\nThis can be overridden by either `.git/config` file, or using the \nfollowing environment variables.\n\n        GIT_AUTHOR_NAME\n        GIT_AUTHOR_EMAIL\n        GIT_AUTHOR_DATE\n        GIT_COMMITTER_NAME\n        GIT_COMMITTER_EMAIL\n        GIT_COMMITTER_DATE\n        EMAIL\n\nHth,\nDscho\n"},{"id":"50940","messageId":"20070817165519.GA28614@istic.org","threadId":"9562","inReplyTo":"20070817163034.GA11151@glandium.org","subject":"Re: Can't figure out some sense from the git-commit-tree man page","fromName":"Daniel Hulme","fromEmail":"st@istic.org","sentAt":"2007-08-17T16:55:19Z","receivedAt":"2007-08-17T16:55:19Z","isPatch":false,"sender":{"key":"st@istic.org","avatar":null},"body":"On Fri, Aug 17, 2007 at 06:30:34PM +0200, Mike Hommey wrote:\n> Hi,\n> \n> The git-commit-tree man page reads:\n>   A commit encapsulates:\n> \n>   ·   all parent object ids\n> \n>   ·   author name, email and date\n> \n>   ·   committer name and email and the commit time.\n>   If not provided, \"git-commit-tree\" uses your name, hostname and domain to\n>   provide author and committer info. This can be overridden by either\n>   .git/config file, or using the following environment variables.\n>   (...)\n> \n> The \"If not provided\" part doesn't make sense. If you're not setting the\n> author and committer in your config or environment, how are you supposed\n> to provide it ?\nMakes sense to me. I interpreted it as:\n\n  If not provided (by one of the ways I'm about to mention), the default\n  is ... This default can be overridden by ...\n\nI can understand how it might be read differently, though. Assuming my\nreading is correct, might something along these lines be clearer:\n\n  To find author and committer info, \"git-commit-tree\" first looks at\n  these environment variables:\n\n  ...\n\n  If they are not set, it tries the keys user.name and user.email from\n  the .git/config file. Finally, it falls back to using your name,\n  hostname, and domain.\n\nEven clearer, though this might be a bit extreme, would be to not\nmention .git/config and say it reads the global or repository-specific\nkeys using git-config.\n\n-- \n\"I like talking to Rabbit.  He talks  about sensible things.  He doesn't\nuse long,  difficult words,  like Owl.  He uses short,  easy words, like\n'What about  lunch?' and  'Help yourself,  Pooh.'  I suppose,  really, I\nought to go and see Rabbit.\"     A. A. Milne, 'The House at Pooh Corner'\n"},{"id":"50937","messageId":"20070817165655.GA13891@glandium.org","threadId":"9562","inReplyTo":"Pine.LNX.4.64.0708171751360.20400@racer.site","subject":"Re: Can't figure out some sense from the git-commit-tree man page","fromName":"Mike Hommey","fromEmail":"mh@glandium.org","sentAt":"2007-08-17T16:56:55Z","receivedAt":"2007-08-17T16:56:55Z","isPatch":false,"sender":{"key":"mh@glandium.org","avatar":"https://avatars.githubusercontent.com/u/1038527?v=4"},"body":"On Fri, Aug 17, 2007 at 05:52:52PM +0100, Johannes Schindelin <Johannes.Schindelin@gmx.de> wrote:\n> Hi,\n> \n> On Fri, 17 Aug 2007, Mike Hommey wrote:\n> \n> >   ?   committer name and email and the commit time.\n> >   If not provided, \"git-commit-tree\" uses your name, hostname and domain to\n> >   provide author and committer info. This can be overridden by either\n> >   .git/config file, or using the following environment variables.\n> >   (...)\n> > \n> > The \"If not provided\" part doesn't make sense.\n> \n> It does, if you know how to specify the committer info.  Which the man \n> page specifies how to provide:\n> \n> This can be overridden by either `.git/config` file, or using the \n> following environment variables.\n> \n>         GIT_AUTHOR_NAME\n>         GIT_AUTHOR_EMAIL\n>         GIT_AUTHOR_DATE\n>         GIT_COMMITTER_NAME\n>         GIT_COMMITTER_EMAIL\n>         GIT_COMMITTER_DATE\n>         EMAIL\n\nThis is exactly where the man page doesn't make sense to me. It tells\nyou that if you don't provide committer name, etc. it uses your name,\nhostname, etc., and you can override this with .git/config or the\nenvironment variable you listed.\n\nSo where were you supposed to provide these informations in the first\nplace ?\n\nMike\n"},{"id":"50938","messageId":"20070817170411.GF28529@fieldses.org","threadId":"9562","inReplyTo":"Pine.LNX.4.64.0708171751360.20400@racer.site","subject":"Re: Can't figure out some sense from the git-commit-tree man page","fromName":"J. Bruce Fields","fromEmail":"bfields@fieldses.org","sentAt":"2007-08-17T17:04:11Z","receivedAt":"2007-08-17T17:04:11Z","isPatch":false,"sender":{"key":"bfields@citi.umich.edu","avatar":null},"body":"On Fri, Aug 17, 2007 at 05:52:52PM +0100, Johannes Schindelin wrote:\n> Hi,\n> \n> On Fri, 17 Aug 2007, Mike Hommey wrote:\n> \n> >   ?   committer name and email and the commit time.\n> >   If not provided, \"git-commit-tree\" uses your name, hostname and domain to\n> >   provide author and committer info. This can be overridden by either\n> >   .git/config file, or using the following environment variables.\n> >   (...)\n> > \n> > The \"If not provided\" part doesn't make sense.\n> \n> It does, if you know how to specify the committer info.\n>\n> Which the man page specifies how to provide:\n\nAt least on a first reading all of the following appears to fall under\nthe \"if not provided\" case.  I know what you mean, but the language here\nis misleading.  One simple fix would be just to delete the words \"If not\nprovided\", or maybe replace them by \"By default, ...\".\n\n--b.\n\n> \n> This can be overridden by either `.git/config` file, or using the \n> following environment variables.\n> \n>         GIT_AUTHOR_NAME\n>         GIT_AUTHOR_EMAIL\n>         GIT_AUTHOR_DATE\n>         GIT_COMMITTER_NAME\n>         GIT_COMMITTER_EMAIL\n>         GIT_COMMITTER_DATE\n>         EMAIL\n"},{"id":"50939","messageId":"Pine.LNX.4.64.0708171808340.20400@racer.site","threadId":"9562","inReplyTo":"20070817165655.GA13891@glandium.org","subject":"Re: Can't figure out some sense from the git-commit-tree man page","fromName":"Johannes Schindelin","fromEmail":"johannes.schindelin@gmx.de","sentAt":"2007-08-17T17:09:17Z","receivedAt":"2007-08-17T17:09:17Z","isPatch":false,"sender":{"key":"johannes.schindelin@gmx.de","avatar":"https://avatars.githubusercontent.com/u/127790?v=4"},"body":"Hi,\n\nOn Fri, 17 Aug 2007, Mike Hommey wrote:\n\n> On Fri, Aug 17, 2007 at 05:52:52PM +0100, Johannes Schindelin <Johannes.Schindelin@gmx.de> wrote:\n> > \n> > On Fri, 17 Aug 2007, Mike Hommey wrote:\n> > \n> > >   ?   committer name and email and the commit time.\n> > >   If not provided, \"git-commit-tree\" uses your name, hostname and domain to\n> > >   provide author and committer info. This can be overridden by either\n> > >   .git/config file, or using the following environment variables.\n> > >   (...)\n> > > \n> > > The \"If not provided\" part doesn't make sense.\n> > \n> > It does, if you know how to specify the committer info.  Which the man \n> > page specifies how to provide:\n> > \n> > This can be overridden by either `.git/config` file, or using the \n> > following environment variables.\n> > \n> >         GIT_AUTHOR_NAME\n> >         GIT_AUTHOR_EMAIL\n> >         GIT_AUTHOR_DATE\n> >         GIT_COMMITTER_NAME\n> >         GIT_COMMITTER_EMAIL\n> >         GIT_COMMITTER_DATE\n> >         EMAIL\n> \n> This is exactly where the man page doesn't make sense to me. It tells\n> you that if you don't provide committer name, etc. it uses your name,\n> hostname, etc., and you can override this with .git/config or the\n> environment variable you listed.\n> \n> So where were you supposed to provide these informations in the first\n> place ?\n\nIn /etc/passwd.  Like on every Unix system.  (Oh yeah, there is NIS and \nother things, but in effect it is the same system.)\n\nCiao,\nDscho\n"},{"id":"50941","messageId":"fa4l5t$3jh$1@sea.gmane.org","threadId":"9562","inReplyTo":"20070817165655.GA13891@glandium.org","subject":"Re: Can't figure out some sense from the git-commit-tree man page","fromName":"Jakub Narebski","fromEmail":"jnareb@gmail.com","sentAt":"2007-08-17T17:16:41Z","receivedAt":"2007-08-17T17:16:41Z","isPatch":false,"sender":{"key":"jnareb@gmail.com","avatar":"https://avatars.githubusercontent.com/u/2706?v=4"},"body":"[Cc: Mike Hommey <mh@glandium.org>, git@vger.kernel.org]\n\nMike Hommey wrote:\n\n> On Fri, Aug 17, 2007 at 05:52:52PM +0100, Johannes Schindelin <Johannes.Schindelin@gmx.de> wrote:\n>> \n>> On Fri, 17 Aug 2007, Mike Hommey wrote:\n>> \n>>>   ?   committer name and email and the commit time.\n>>>   If not provided, \"git-commit-tree\" uses your name, hostname and domain to\n>>>   provide author and committer info. This can be overridden by either\n>>>   .git/config file, or using the following environment variables.\n>>>   (...)\n>>> \n>>> The \"If not provided\" part doesn't make sense.\n>> \n>> It does, if you know how to specify the committer info.  Which the man \n>> page specifies how to provide:\n>> \n>> This can be overridden by either `.git/config` file, or using the \n>> following environment variables.\n>> \n>>         GIT_AUTHOR_NAME\n>>         GIT_AUTHOR_EMAIL\n>>         GIT_AUTHOR_DATE\n>>         GIT_COMMITTER_NAME\n>>         GIT_COMMITTER_EMAIL\n>>         GIT_COMMITTER_DATE\n>>         EMAIL\n> \n> This is exactly where the man page doesn't make sense to me. It tells\n> you that if you don't provide committer name, etc. it uses your name,\n> hostname, etc., and you can override this with .git/config or the\n> environment variable you listed.\n> \n> So where were you supposed to provide these informations in the first\n> place ?\n\nWhere you are supposed to provide this information? In .git/config (per\nrepository) or in ~/.gitconfig (per user), in the form:\n\n[user]\n        name  = Mike Hommey\n        email = mh@glandium.org\n\n\n\"If not provided\" means that git gets your user name from system, from the\nGECOS files in /etc/passwd, and composes your email address from your user\nid (account name), and from the hostname of your machine (or \"(localhost)\").\nThis is last resort fallback, so you better provide user and email yourself.\n-- \nJakub Narebski\nWarsaw, Poland\nShadeHawk on #git\n"},{"id":"50944","messageId":"20070817172323.GA14145@glandium.org","threadId":"9562","inReplyTo":"20070817170411.GF28529@fieldses.org","subject":"Re: Can't figure out some sense from the git-commit-tree man page","fromName":"Mike Hommey","fromEmail":"mh@glandium.org","sentAt":"2007-08-17T17:23:23Z","receivedAt":"2007-08-17T17:23:23Z","isPatch":false,"sender":{"key":"mh@glandium.org","avatar":"https://avatars.githubusercontent.com/u/1038527?v=4"},"body":"On Fri, Aug 17, 2007 at 01:04:11PM -0400, J. Bruce Fields <bfields@fieldses.org> wrote:\n> On Fri, Aug 17, 2007 at 05:52:52PM +0100, Johannes Schindelin wrote:\n> > Hi,\n> > \n> > On Fri, 17 Aug 2007, Mike Hommey wrote:\n> > \n> > >   ?   committer name and email and the commit time.\n> > >   If not provided, \"git-commit-tree\" uses your name, hostname and domain to\n> > >   provide author and committer info. This can be overridden by either\n> > >   .git/config file, or using the following environment variables.\n> > >   (...)\n> > > \n> > > The \"If not provided\" part doesn't make sense.\n> > \n> > It does, if you know how to specify the committer info.\n> >\n> > Which the man page specifies how to provide:\n> \n> At least on a first reading all of the following appears to fall under\n> the \"if not provided\" case.  I know what you mean, but the language here\n> is misleading.  One simple fix would be just to delete the words \"If not\n> provided\", or maybe replace them by \"By default, ...\".\n\nI think it would be better to put the fact that \"If not provided...\"\n*after* telling that you can provide author, committer, etc. by setting\nenvironment or editing the conf.\n\nMike\n"},{"id":"50946","messageId":"20070817173622.GI28529@fieldses.org","threadId":"9562","inReplyTo":"20070817172323.GA14145@glandium.org","subject":"Re: Can't figure out some sense from the git-commit-tree man page","fromName":"J. Bruce Fields","fromEmail":"bfields@fieldses.org","sentAt":"2007-08-17T17:36:22Z","receivedAt":"2007-08-17T17:36:22Z","isPatch":false,"sender":{"key":"bfields@citi.umich.edu","avatar":null},"body":"On Fri, Aug 17, 2007 at 07:23:23PM +0200, Mike Hommey wrote:\n> I think it would be better to put the fact that \"If not provided...\"\n> *after* telling that you can provide author, committer, etc. by setting\n> environment or editing the conf.\n\nYup, probably.  Patch?\n\n--b.\n"},{"id":"50953","messageId":"20070817201336.GA20300@glandium.org","threadId":"9562","inReplyTo":"20070817173622.GI28529@fieldses.org","subject":"[PATCH] Clarify commit-tree documentation","fromName":"Mike Hommey","fromEmail":"mh@glandium.org","sentAt":"2007-08-17T20:13:36Z","receivedAt":"2007-08-17T20:13:36Z","isPatch":true,"sender":{"key":"mh@glandium.org","avatar":"https://avatars.githubusercontent.com/u/1038527?v=4"},"body":"As per http://marc.info/?l=git&m=118737219702802&w=2 , clarify\ngit-commit-tree documentation.\n\nSigned-off-by: Mike Hommey <mh@glandium.org>\n---\n Documentation/git-commit-tree.txt |   15 ++++++---------\n 1 files changed, 6 insertions(+), 9 deletions(-)\n\ndiff --git a/Documentation/git-commit-tree.txt b/Documentation/git-commit-tree.txt\nindex 5870c2c..6a328f4 100644\n--- a/Documentation/git-commit-tree.txt\n+++ b/Documentation/git-commit-tree.txt\n@@ -51,9 +51,9 @@ A commit encapsulates:\n - author name, email and date\n - committer name and email and the commit time.\n \n-If not provided, \"git-commit-tree\" uses your name, hostname and domain to\n-provide author and committer info. This can be overridden by\n-either `.git/config` file, or using the following environment variables.\n+While parent object ids are provided on the command line, author and\n+commiter information is taken from the following environment variables,\n+if set:\n \n \tGIT_AUTHOR_NAME\n \tGIT_AUTHOR_EMAIL\n@@ -65,12 +65,9 @@ either `.git/config` file, or using the following environment variables.\n \n (nb \"<\", \">\" and \"\\n\"s are stripped)\n \n-In `.git/config` file, the following items are used for GIT_AUTHOR_NAME and\n-GIT_AUTHOR_EMAIL:\n-\n-\t[user]\n-\t\tname = \"Your Name\"\n-\t\temail = \"your@email.address.xz\"\n+In case (some of) these environment variables are not set, the information\n+is taken from the configuration items user.name and user.email, or, if not\n+present, system user name and fully qualified hostname.\n \n A commit comment is read from stdin. If a changelog\n entry is not provided via \"<\" redirection, \"git-commit-tree\" will just wait\n-- \n1.5.3.rc4\n"},{"id":"50971","messageId":"7vps1len4q.fsf@gitster.siamese.dyndns.org","threadId":"9562","inReplyTo":"20070817201336.GA20300@glandium.org","subject":"Re: [PATCH] Clarify commit-tree documentation","fromName":"Junio C Hamano","fromEmail":"gitster@pobox.com","sentAt":"2007-08-17T23:51:01Z","receivedAt":"2007-08-17T23:51:01Z","isPatch":true,"sender":{"key":"gitster@pobox.com","avatar":"https://avatars.githubusercontent.com/u/54884?v=4"},"body":"Sounds good.  Thanks.\n"}]}