git.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: "Jakub Narębski" <jnareb@gmail.com>
To: Lawrence Siebert <lawrencesiebert@gmail.com>
Cc: git@vger.kernel.org,
	Johannes Schindelin <Johannes.Schindelin@gmx.de>,
	John Keeping <john@keeping.me.uk>
Subject: Re: [PATCH] --count feature for git shortlog
Date: Tue, 21 Jul 2015 20:27:28 +0200	[thread overview]
Message-ID: <55AE8F10.8080905@gmail.com> (raw)
In-Reply-To: <CAKDoJU7om3DBVYMD_yYet_cGep12RCUePtvFS7=TdW_1rkuE+Q@mail.gmail.com>

Lawrence Siebert wrote:
> On Fri, Jul 3, 2015 at 10:31 AM, Junio C Hamano <gitster@pobox.com> wrote:
>> John Keeping <john@keeping.me.uk> writes:

>>> Or even `git rev-list --count HEAD -- "$FILENAME"`.
>>
>> Ahh, OK.  I didn't know we already had "rev-list --count".
>>
>> Then please disregard the suggestion to add the option to "log"; it
>> still holds true that the option does not belong to "shortlog", but
>> I do think "how many changes were made to this path" statistics
>> driven by a script should use "rev-list" plumbing, and if it already
>> has "--count" option, that is perfect ;-)
>>
> Junio,
> 
> I think, respectfully, there is still a benefit to adding it as a
> feature to "log", in that more Git users know of and use "log" than
> "rev-list". I hadn't heard of "rev-list" before joining this mailing
> list.
> 
> That means "log --count" will get used more. That also means that more
> eyeballs will hit --count with bug reports and better tests; I've
> already seen 2-3 suggestions for "log --count" tests that "rev-list
> --count" also doesn't have tests for.
> 
> I would like to keep working on implementing "log --count", sharing
> code with rev-list where possible so they both are improved, unless
> you are saying you won't merge.

Lawrence,

As git-rev-list is (mainly) plumbing for git-log porcelain, I think
what you would need to do to add "--count" support to "git log" is
just parse option, exclude nonsense combinations, and pass down to
the revision parsing machinery.

HTH
-- 
Jakub Narębski

      reply	other threads:[~2015-07-21 18:28 UTC|newest]

Thread overview: 15+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2015-06-29  1:22 [PATCH] --count feature for git shortlog Lawrence Siebert
2015-06-29  1:22 ` Lawrence Siebert
2015-06-29  1:22 ` Lawrence Siebert
2015-06-29  4:37 ` Junio C Hamano
     [not found]   ` <CAKDoJU4HcGoOS83MKwsQBXztYrDomMd9N-2SKc6iRyNhQQM5Eg@mail.gmail.com>
2015-06-29 16:46     ` Lawrence Siebert
2015-06-29 17:04       ` Junio C Hamano
2015-06-29 21:33         ` Lawrence Siebert
2015-06-30 12:10       ` Johannes Schindelin
2015-06-30 12:23         ` John Keeping
     [not found]           ` <CAKDoJU4cEvWvfnFsvfOJ_P0UOrD3RpLK1NdfxaUPiDTWXYg-oA@mail.gmail.com>
2015-07-01  3:00             ` Lawrence Siebert
2015-07-01 11:50               ` Jeff King
2015-07-01 15:15                 ` Junio C Hamano
2015-07-03 17:31           ` Junio C Hamano
2015-07-03 23:32             ` Lawrence Siebert
2015-07-21 18:27               ` Jakub Narębski [this message]

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=55AE8F10.8080905@gmail.com \
    --to=jnareb@gmail.com \
    --cc=Johannes.Schindelin@gmx.de \
    --cc=git@vger.kernel.org \
    --cc=john@keeping.me.uk \
    --cc=lawrencesiebert@gmail.com \
    /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).