git@vger.kernel.org mailing list mirror (one of many)
 help / color / mirror / code / Atom feed
* [PATCH] annotate should number lines starting with 1
@ 2006-03-02 23:27 Luck, Tony
  2006-03-03  7:09 ` Junio C Hamano
  2006-03-03  7:09 ` Junio C Hamano
  0 siblings, 2 replies; 3+ messages in thread
From: Luck, Tony @ 2006-03-02 23:27 UTC (permalink / raw
  To: git

C programmers are well used to counting from zero, but every
other text file tool starts counting from 1.

Signed-off-by: Tony Luck <tony.luck@intel.com>

---

diff --git a/git-annotate.perl b/git-annotate.perl
index 08d479f..d93ee19 100755
--- a/git-annotate.perl
+++ b/git-annotate.perl
@@ -128,7 +128,7 @@ foreach my $l (@filelines) {
 	}
 
 	printf("%s\t(%10s\t%10s\t%d)%s\n", $rev, $committer,
-		format_date($date), $i++, $output);
+		format_date($date), ++$i, $output);
 }
 
 sub init_claim {

^ permalink raw reply related	[flat|nested] 3+ messages in thread

* Re: [PATCH] annotate should number lines starting with 1
  2006-03-02 23:27 [PATCH] annotate should number lines starting with 1 Luck, Tony
@ 2006-03-03  7:09 ` Junio C Hamano
  2006-03-03  7:09 ` Junio C Hamano
  1 sibling, 0 replies; 3+ messages in thread
From: Junio C Hamano @ 2006-03-03  7:09 UTC (permalink / raw
  To: Luck, Tony; +Cc: git, Martin Langhoff

"Luck, Tony" <tony.luck@intel.com> writes:

> C programmers are well used to counting from zero, but every
> other text file tool starts counting from 1.

Thanks.

I agree with this patch 100%, so I am going to take this patch.

But git-cvsserver might need some adjustments.
Martin?

^ permalink raw reply	[flat|nested] 3+ messages in thread

* Re: [PATCH] annotate should number lines starting with 1
  2006-03-02 23:27 [PATCH] annotate should number lines starting with 1 Luck, Tony
  2006-03-03  7:09 ` Junio C Hamano
@ 2006-03-03  7:09 ` Junio C Hamano
  1 sibling, 0 replies; 3+ messages in thread
From: Junio C Hamano @ 2006-03-03  7:09 UTC (permalink / raw
  To: Luck, Tony; +Cc: git, Martin Langhoff

"Luck, Tony" <tony.luck@intel.com> writes:

> C programmers are well used to counting from zero, but every
> other text file tool starts counting from 1.

Thanks.

I agree with this patch 100%, so I am going to take this patch.

But git-cvsserver might need some adjustments.
Martin?

^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2006-03-03  7:10 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2006-03-02 23:27 [PATCH] annotate should number lines starting with 1 Luck, Tony
2006-03-03  7:09 ` Junio C Hamano
2006-03-03  7:09 ` Junio C Hamano

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).