git/list[1] front-page[2] threads[3] people[4] search[5] about
 

Re: Possibly a bug

From
Jeff King <peff@peff.net>
Date
Nov 17, 2013, 09:49 UTC
Message-ID
<20131117094946.GA22166@sigill.intra.peff.net>
In-Reply-To
<CAJbVpmyoZCCQU3w8oMTJfxFr4f1cSNTgF+qQW6QD5e44LYg_Ug@mail.gmail.com>
On Sun, Nov 17, 2013 at 04:59:20AM +0200, Jiergir Ogoerg wrote:
Show 8 quoted lines
> As suggested by the git book/tutorial I cloned "simplegit-progit" to
> learn using git.
> The issue:
> git log --since=5.years
> yields 2 commits, while
> git log --since=6.years
> yields 3 commits, despite the "Date" in both cases being March 2008.
> Is it a bug?
No, but it is confusing.

The `--since` and `--until` flags use the committer date, not the author date. Try `git log --pretty=fuller`, and you will see that the author and committer dates do not match for the top two commits (their committer date is within 5 years).

Usually the two dates are the same, but they can be different if a commit is rebased, or applied via patch.

-Peff
Previous: Jiergir Ogoerg
Message 2 of 2 in “Possibly a bug”
  1. Jiergir OgoergNov 17, 2013
  2. Jeff KingNov 17, 2013

Read the whole thread, see it on lore, or plain text.

$ cat FOOTERMessages come from the public archive at lore.kernel.org/git, fetched every hour. The front page is chosen and written each morning by an AI editor and can be wrong; the threads themselves are the record. About and API. For agents: an MCP server at https://gitlist.dev/mcp, and any thread, story or person page as Markdown by adding .md to its URL (or sending Accept: text/markdown). Details in /llms.txt.