From: Vincent Lefevre <vincent@vinc17.net>
To: git@vger.kernel.org
Subject: Strange behavior of "git log" with file argument
Date: Fri, 19 Jun 2026 17:44:48 +0200 [thread overview]
Message-ID: <20260619154448.GA769454@qaa.vinc17.org> (raw)
With 2.53.0 under Debian/unstable:
* https://github.com/git/git.git repository
at 95e20213faefeb95df29277c58ac1980ab68f701
"git log git-gui/git-gui--askyesno.sh" outputs nothing. To get logs, I
can add the -m option. In particular, this shows 3 non-merge commits.
So the behavior without -m seems incorrect, and at least unhelpful.
* https://gitlab.inria.fr/mpfr/mpfr.git repository
at 74cb29f0908c2887dc8c3e6ba7a3c5a2f20710a3
"git log --reverse AUTHORS" shows only 2 commits:
bfa9d064e1cf7a736740c73b9773eabb11da6ed7
5a9521d1f305268e575c4a5c4de13614acef6321
where bfa9d064e1cf7a736740c73b9773eabb11da6ed7 corresponds to the file
creation and 5a9521d1f305268e575c4a5c4de13614acef6321 is unrelated to
the AUTHORS file:
git show 5a9521d1f305268e575c4a5c4de13614acef6321
contains nothing about AUTHORS, and "git log AUTHORS" does not list
this commit. But "git log AUTHORS" also lists
b28347ab59db2a99168a17c3e1804000069199aa
which had been done *before* the AUTHORS file was created!
Note: According to the git-log(1) man page, the --reverse option
is supposed to affect only the order, not the list of commits to
be shown:
--reverse
Output the commits chosen to be shown (see Commit Limiting section
above) in reverse order. Cannot be combined with --walk-reflogs.
--
Vincent Lefèvre <vincent@vinc17.net> - Web: <https://www.vinc17.net/>
100% accessible validated (X)HTML - Blog: <https://www.vinc17.net/blog/>
Work: CR INRIA - computer arithmetic / Pascaline project (LIP, ENS-Lyon)
next reply other threads:[~2026-06-19 15:47 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-06-19 15:44 Vincent Lefevre [this message]
2026-06-19 17:02 ` Strange behavior of "git log" with file argument Junio C Hamano
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=20260619154448.GA769454@qaa.vinc17.org \
--to=vincent@vinc17.net \
--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