5

For example:

  • How can I display when HEAD@{2} was created?
  • Given a commit's SHA1, how can I display the date it was pulled into the current repo, rather than (or in addition to) its commit date?

I thought there would be a git reflog option for this, but as far as I can see, there is not.

4

1 回答 1

5

git reflog --date=iso

将显示带有日期的 reflog。

手册页中间接提到了这一点:

子命令“show”(这也是默认的,在没有任何子命令的情况下)将采用所有正常的日志选项[...]

为了更好地控制 reflog 格式,您还可以使用git log -g,它也显示 reflog。

于 2013-10-30T22:04:30.967 回答