From: Junio C Hamano <gitster@pobox.com>
To: Johannes Schindelin <Johannes.Schindelin@gmx.de>
Cc: "Ingo Molnar" <mingo@elte.hu>,
"René Scharfe" <rene.scharfe@lsrfire.ath.cx>,
"roel kluin" <roel.kluin@gmail.com>,
git@vger.kernel.org, LKML <linux-kernel@vger.kernel.org>,
"Andrew Morton" <akpm@linux-foundation.org>
Subject: Re: [PATCH] fread does not return negative on error
Date: Wed, 24 Jun 2009 09:15:20 -0700 [thread overview]
Message-ID: <7vws71wquf.fsf@alter.siamese.dyndns.org> (raw)
In-Reply-To: <alpine.DEB.1.00.0906241201040.4773@pacific.mpi-cbg.de> (Johannes Schindelin's message of "Wed\, 24 Jun 2009 12\:03\:29 +0200 \(CEST\)")
Johannes Schindelin <Johannes.Schindelin@gmx.de> writes:
> This here script:
>
> -- snip --
> for file in abspath.c alias.c cache.h color.c color.h config.c ctype.c \
> environment.c exec_cmd.c exec_cmd.h help.c help.h levenshtein.c \
> levenshtein.h pager.c parse-options.c parse-options.h path.c \
> quote.c quote.h run-command.c run-command.h sigchain.c sigchain.h \
> strbuf.c strbuf.h string.c string.h symbol.c symbol.h usage.c \
> util.h wrapper.c
> do
> echo $file
> git shortlog -n -s $file | head -n 2
> done
I have thought about suggesting this myself, and your output for many of
the files matched my intuition, but some were grossly off, so I checked.
The above procedure counts commits, and a one liner "s/char \*/const &/"
weighs as heavily as the patch that implemented the whole thing, for a
file that was done in one commit almost perfectly except that it needed a
small constness fix. Summarizing output from "blame" for each file may
give you a more meaningful results:
# timestamp
ts='[12][0-9][0-9][0-9]-[0-9][0-9]-[0-3][0-9] ..:..:.. [-+]....'
# linenum
lno='[1-9][0-9]*'
git blame "$file" |
sed -e 's/^[^ ]* *(\([^)]*[^ ]\) *'"$ts *$lno"').*/\1/' |
sort |
uniq -c |
sort -r -n
For example, I do not think it is fair to credit me for abspath.c more
than Dmitry like this:
> outputs this (note that a few files you mentioned are not in git.git):
>
> abspath.c
> 2 Junio C Hamano
> 1 Dmitry Potapov
Initially Dmitry introduced this file with 5b8e6f8 (shrink git-shell by
avoiding redundant dependencies, 2008-06-28) at 68 lines. J6t added 36
lines for add_path() with 10c4c88 (Allow add_path() to add non-existent
directories to the path, 2008-07-21), I added 12 lines to add a new
function with 90b4a71 (is_directory(): a generic helper function,
2008-09-09) and then added a two-liner out-of-bounds-then-die check in
737e31a (make_absolute_path(): check bounds when seeing an overlong
symlink, 2008-12-17).
next prev parent reply other threads:[~2009-06-24 16:15 UTC|newest]
Thread overview: 14+ messages / expand[flat|nested] mbox.gz Atom feed top
[not found] <4A3FB09D.9050903@gmail.com>
2009-06-22 15:34 ` [PATCH] tools: fread does not return negative on error Ingo Molnar
2009-06-22 15:47 ` roel kluin
2009-06-22 16:42 ` [PATCH] " René Scharfe
2009-06-23 23:56 ` Junio C Hamano
2009-06-24 8:18 ` Ingo Molnar
2009-06-24 10:03 ` Johannes Schindelin
2009-06-24 16:15 ` Junio C Hamano [this message]
2009-06-24 16:40 ` Johannes Schindelin
2009-06-24 17:59 ` Ingo Molnar
2009-06-24 21:19 ` Alex Riesen
2009-06-24 21:55 ` Junio C Hamano
2009-06-24 10:53 ` Christian Couder
2009-06-24 12:12 ` Ingo Molnar
2009-06-25 18:31 ` 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
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=7vws71wquf.fsf@alter.siamese.dyndns.org \
--to=gitster@pobox.com \
--cc=Johannes.Schindelin@gmx.de \
--cc=akpm@linux-foundation.org \
--cc=git@vger.kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=mingo@elte.hu \
--cc=rene.scharfe@lsrfire.ath.cx \
--cc=roel.kluin@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.
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).