rev-list: introduce --count option
authorThomas Rast <trast@student.ethz.ch>
Thu, 10 Jun 2010 11:47:23 +0000 (13:47 +0200)
committerJunio C Hamano <gitster@pobox.com>
Sat, 12 Jun 2010 16:39:06 +0000 (09:39 -0700)
Add a --count option that, instead of actually listing the commits,
merely counts them.

This is mostly geared towards script use, and to this end it acts
specially when used with --left-right: it outputs the left and right
counts separately. Previously, scripts would have to run a shell loop
or small inline script over to achieve the same. (Without
--left-right, a simple |wc -l does the job.)

Signed-off-by: Thomas Rast <trast@student.ethz.ch>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
No differences found