git@vger.kernel.org mailing list mirror (one of many)
 help / color / mirror / code / Atom feed
From: Norbert Kiesel <nkiesel@gmail.com>
To: Git Mailing List <git@vger.kernel.org>
Subject: [git 2.26] stat counts reported by commit and log are different
Date: Wed, 8 Apr 2020 19:04:02 -0700	[thread overview]
Message-ID: <CAM+g_Nv4UqQNAuYyo5zsTsiomCe4ueoM6ZGU1aqAjLGV9+jQJg@mail.gmail.com> (raw)

Hi,

I just noticed that the numbers reported are different:

% git commit -m 'major code cleanup for SCIMPatchOperationUtil'
[nkiesel/nextrelease/SCIM_2 d4db6f6d83f] major code cleanup for
SCIMPatchOperationUtil
 1 file changed, 2106 insertions(+), 3367 deletions(-)
 rewrite utils/SCIMPatchOperationUtil.java (74%)
% git log --stat -1
commit d4db6f6d83f (HEAD -> nkiesel/nextrelease/SCIM_2)
Author: Norbert Kiesel <nkiesel@metricstream.com>
Date:   Wed Apr 8 18:49:27 2020 -0700

    major code cleanup for SCIMPatchOperationUtil

 utils/SCIMPatchOperationUtil.java | 3807
+++++++++++++++++++++++++++++++++++++++++++++++++++++----------------------------------------------------------------------------------------------------------
 1 file changed, 1273 insertions(+), 2534 deletions(-)
% wc -l utils/SCIMPatchOperationUtil.java
2106 utils/SCIMPatchOperationUtil.java

As you can see, the number of lines in the current file match the
number of insertions reported by commit.  I suspect some "automated
line ending conversion magic" is at fault here (the file has "\r\n"
for my Windows-impaired co-developers but I modified it on a Linux
system). `git config --get core.autocrlf` on my machine returns
`input`.  However, I think it would still be better to always report
the same numbers, no?

             reply	other threads:[~2020-04-09  2:04 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2020-04-09  2:04 Norbert Kiesel [this message]
2020-04-09 13:59 ` [git 2.26] stat counts reported by commit and log are different Jeff King
2020-04-09 21:58   ` Norbert Kiesel
2020-04-09 22:47     ` Jeff King
2020-04-09 22:55       ` Junio C Hamano
2020-04-09 23:12         ` 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

  List information: http://vger.kernel.org/majordomo-info.html

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=CAM+g_Nv4UqQNAuYyo5zsTsiomCe4ueoM6ZGU1aqAjLGV9+jQJg@mail.gmail.com \
    --to=nkiesel@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.
Code repositories for project(s) associated with this public inbox

	https://80x24.org/mirrors/git.git

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 read-only IMAP folder(s) and NNTP newsgroup(s).