Re: Possible bug in git log with date ranges
- From
Ævar Arnfjörð Bjarmason <avarab@gmail.com>
- Date
- Apr 2, 2018, 12:17 UTC
- Message-ID
- <871sfxx0od.fsf@evledraar.gmail.com>
- In-Reply-To
- <CAFGVh0yh-w3=s5WBK-HqHQd+dWKgpnqytF4E3mXv_HxrC1i78Q@mail.gmail.com>
On Mon, Apr 02 2018, David Hoyle wrote:
Show 14 quoted lines
> Hi, > > Hopefully I've read the readme file correctly for submitting something > that might be a bug. > > I've recently migrated projects from an old version control system > (JEDI VCS) to Git (which I really like BTW). The way this was done was > by extracting the files from the original database and saving them to > a folder layout and then running git add / commit on the files. When > using the commit command I've used the --date switch to commit the > files using their original dates. However if I run git log with say > --since=date it seems as if this command uses the actual date the > commit was entered not the date given for the commit. The same seems > to apply to the other date filtering switches.
The --date=* switch to git-commit sets the author date, but the date narrowing options to git-log use the committer date. See if when you run:
git log --pretty=format:"%aD - %cD"
Whether what you're getting doesn't make sense in terms of the second date.
You can use GIT_COMMITTER_DATE to get what you want, see "DATE FORMATS" in git-commit(1).