git.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Jeff King <peff@peff.net>
To: "Eirik Bjørsnøs" <eirbjo@gmail.com>
Cc: git@vger.kernel.org
Subject: Re: Invalid dates in git log
Date: Wed, 12 Dec 2007 04:23:04 -0500	[thread overview]
Message-ID: <20071212092304.GA20799@coredump.intra.peff.net> (raw)
In-Reply-To: <34660cca0712120111k3f11769fk1a8cefda3b82683e@mail.gmail.com>

On Wed, Dec 12, 2007 at 10:11:12AM +0100, Eirik Bjørsnøs wrote:

> My questions are:
> 
> 1) Is this a problem in the Git software?

No. Whoever made the commit probably just didn't have their clock set
right. Git doesn't generally care about the timestamp for its
operations; it just records it as a historical note.

> 2) Or is it a data corruption issue in the repository?

No. You can check for corruption with git-fsck, but these commits were
actually created with bad dates.

> 3) Can it be fixed and should I contact anyone to get it fixed?

Changing the date will change the commit id (since the id is the sha1 of
the commit contents). Which would mean rewriting all of the history that
follows it. You could do it in your own repository, but then you might
have some trouble merging with Linus later on. Linus could do it, but I
doubt he will think it is worth the trouble.

> $ git  log  a27ac38efd6dc6dccebfc9bcc475ab4aa5fc4a56 -1
> commit a27ac38efd6dc6dccebfc9bcc475ab4aa5fc4a56
> Author: Len Brown <len.brown@intel.com>
> Date:   Fri Apr 5 00:07:45 2019 -0500

Your best guess is probably the committer information. Try this:

  git log a27ac38 -1 --pretty=format:'Author: %an %ad%nCommitter: %cn %cd'

-Peff

  reply	other threads:[~2007-12-12  9:23 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 [this message]
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

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=20071212092304.GA20799@coredump.intra.peff.net \
    --to=peff@peff.net \
    --cc=eirbjo@gmail.com \
    --cc=git@vger.kernel.org \
    /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).