From: Andreas Ericsson <ae@op5.se>
To: "Eirik Bjørsnøs" <eirbjo@gmail.com>
Cc: Jeff King <peff@peff.net>, git@vger.kernel.org
Subject: Re: Invalid dates in git log
Date: Wed, 12 Dec 2007 16:51:46 +0100 [thread overview]
Message-ID: <47600392.5050809@op5.se> (raw)
In-Reply-To: <34660cca0712120619r708ee7a8ta20a5458ca11a5ac@mail.gmail.com>
Eirik Bjørsnøs wrote:
>> Your best guess is probably the committer information. Try this:
>
> Thanks Jeff, Junio,
>
> I'll just use the committer date instead.
>
> Being a Git newbie (only started looking at it yesterday) I'm not sure
> my understanding of "author" and "committer" and how they releate to
> dates is correct:
>
They're often the same. They will end up being different if
* you cherry-pick a commit made by someone else.
("someone else" is author, you are the committer)
* you rebase a series of commit containing changes from others
("others" are the authors, you are the committer)
* you apply a patch using "git am" from someone
("someone" is the author, you are the committer)
* you "git commit --amend" a commit from someone else
("someone else" is author, you are the committer)
There are probably other cases, but those were the ones I could
think of right now.
In short, whenever a commit is modified in some way, it gets a
new committer. It might help if you think of author as "contributor"
and "committer" as "integrator", where various integrators merge
between each other. A merge obviously doesn't fiddle with commits,
so once a commit has entered an integrators repository, both author
and committer stays intact (that's not strictly true, but for the
sake of this argument, which concerns the linux kernel, it will
suffice and be mostly correct insofar as I understand the kernel
workflow).
> * author: Original source of the change. This person may typically
> have sent a committer an email with a patch. It's the commiter's
> responsibility to supply this information.
No, it's the author's responsibility to supply this information.
Author is hardly ever changed.
> * author date: The commiter is free to specify a date for the contribution.
>
No, the author does that too :)
> * committer: First committer to actually add this change to a repository
No, committer is the person who added the commit to the repository by
some other means than merging from another repository.
> * committer date: Date of the actual commit, added by the git client
> during the commit. Typically the system clock at the time of the
> commit.
>
Sort of, yes, although commits can be created by other means than
just running "git commit". The operations listed in bullets at the
top of this mail all create new commits, in the sense that they
can't have the same SHA1 as their original ones. Hence, committer
and commitdate must be updated.
> * A transfer of a commit across repositories (pull, push) will not
> change the author, commit or date information
>
True. Since neither ancestry nor content is allowed to change, the
commit will be exactly the same in the new repository as it was in
the old one.
> If I got some of this wrong, I'd be happy if someone would correct me.
>
I think I just did. Perhaps I missed something, but I'm sure someone
will correct me if that's the case.
--
Andreas Ericsson andreas.ericsson@op5.se
OP5 AB www.op5.se
Tel: +46 8-230225 Fax: +46 8-230231
prev parent reply other threads:[~2007-12-12 15:52 UTC|newest]
Thread overview: 7+ messages / expand[flat|nested] mbox.gz Atom feed top
2007-12-12 9:11 Invalid dates in git log Eirik Bjørsnøs
2007-12-12 9:23 ` Jeff King
2007-12-12 9:35 ` Junio C Hamano
2007-12-12 14:59 ` Johannes Schindelin
2007-12-12 18:57 ` Junio C Hamano
2007-12-12 14:19 ` Eirik Bjørsnøs
2007-12-12 15:51 ` Andreas Ericsson [this message]
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=47600392.5050809@op5.se \
--to=ae@op5.se \
--cc=eirbjo@gmail.com \
--cc=git@vger.kernel.org \
--cc=peff@peff.net \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
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).