From: Ephrim Khong <dr.khong@gmail.com>
To: git@vger.kernel.org
Subject: git log omits deleting merges
Date: Thu, 20 Feb 2014 08:35:33 +0100 [thread overview]
Message-ID: <5305B045.2060503@gmail.com> (raw)
Hi, git log seems to omit merge commits that delete a file if --follow
or --diff-filter=D is given. Below is a testcase. I'm not sure if it is
desired behaviour for --diff-filter=D, but it's probably not correct
that --follow _removes_ the merge commit from the log output.
Thanks - Eph
--
git init
touch some_file
git add some_file
git commit -m "initial"
git branch other_branch
echo foo > some_file
git commit -a -m "commit in master"
git checkout other_branch
echo bar > some_file
git commit -a -m "commit in other_branch"
git merge master --no-commit
rm some_file
git rm some_file
git commit -m "merge"
echo "log 1 - no output"
# note that --diff-filter=A and M work as expected
# the merge does not show up for --diff-filter=ACDMRTUXB either
git log --pretty=oneline --diff-filter=D -- some_file
echo "log 2 - merge is missing"
git log --pretty=oneline --follow --all -- some_file
echo "log 3 - complete"
git log --pretty=oneline --all -- some_file
--
next reply other threads:[~2014-02-20 7:35 UTC|newest]
Thread overview: 6+ messages / expand[flat|nested] mbox.gz Atom feed top
2014-02-20 7:35 Ephrim Khong [this message]
2014-03-20 19:54 ` git log omits deleting merges Jeff King
2014-03-20 22:56 ` Philip Oakley
2014-03-21 5:23 ` Jeff King
2014-03-24 10:25 ` Ephrim Khong
2014-03-24 14:19 ` Jeff King
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=5305B045.2060503@gmail.com \
--to=dr.khong@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).