# [PATCH] gitweb: fix spelling errors in comments

3 messages from 2009-09-26 to 2009-09-27. Participants: Miklos Vajna, Jeff King.
Thread: https://gitlist.dev/t/21070

## Miklos Vajna, 2009-09-26 23:32

Subject: [PATCH] gitweb: fix spelling errors in comments
Message-ID: <1254007953-1961-1-git-send-email-vmiklos@frugalware.org>
URL: https://gitlist.dev/e/1254007953-1961-1-git-send-email-vmiklos%40frugalware.org

```
Signed-off-by: Miklos Vajna <vmiklos@frugalware.org>
---
 gitweb/gitweb.perl |   10 +++++-----
 1 files changed, 5 insertions(+), 5 deletions(-)

The plural form of "id" is "ids", not "id's", right?

diff --git a/gitweb/gitweb.perl b/gitweb/gitweb.perl
index 24b2193..b66c4d0 100755
--- a/gitweb/gitweb.perl
+++ b/gitweb/gitweb.perl
@@ -4949,7 +4949,7 @@ sub git_blob_plain {
 			die_error(400, "No file name defined");
 		}
 	} elsif ($hash =~ m/^[0-9a-fA-F]{40}$/) {
-		# blobs defined by non-textual hash id's can be cached
+		# blobs defined by non-textual hash ids can be cached
 		$expires = "+1d";
 	}
 
@@ -5001,7 +5001,7 @@ sub git_blob {
 			die_error(400, "No file name defined");
 		}
 	} elsif ($hash =~ m/^[0-9a-fA-F]{40}$/) {
-		# blobs defined by non-textual hash id's can be cached
+		# blobs defined by non-textual hash ids can be cached
 		$expires = "+1d";
 	}
 
@@ -5346,7 +5346,7 @@ sub git_commit {
 	@difftree = map { chomp; $_ } <$fd>;
 	close $fd or die_error(404, "Reading git-diff-tree failed");
 
-	# non-textual hash id's can be cached
+	# non-textual hash ids can be cached
 	my $expires;
 	if ($hash =~ m/^[0-9a-fA-F]{40}$/) {
 		$expires = "+1d";
@@ -5513,7 +5513,7 @@ sub git_blobdiff {
 		$hash_parent ||= $diffinfo{'from_id'};
 		$hash        ||= $diffinfo{'to_id'};
 
-		# non-textual hash id's can be cached
+		# non-textual hash ids can be cached
 		if ($hash_base =~ m/^[0-9a-fA-F]{40}$/ &&
 		    $hash_parent_base =~ m/^[0-9a-fA-F]{40}$/) {
 			$expires = '+1d';
@@ -5733,7 +5733,7 @@ sub git_commitdiff {
 		die_error(400, "Unknown commitdiff format");
 	}
 
-	# non-textual hash id's can be cached
+	# non-textual hash ids can be cached
 	my $expires;
 	if ($hash =~ m/^[0-9a-fA-F]{40}$/) {
 		$expires = "+1d";
-- 
1.6.5.rc1.44.ga1675.dirty

```

## Jeff King, 2009-09-27 08:35

Subject: Re: [PATCH] gitweb: fix spelling errors in comments
Message-ID: <20090927083507.GA25891@coredump.intra.peff.net>
URL: https://gitlist.dev/e/20090927083507.GA25891%40coredump.intra.peff.net
In-Reply-To: <1254007953-1961-1-git-send-email-vmiklos@frugalware.org>

```
On Sun, Sep 27, 2009 at 01:32:33AM +0200, Miklos Vajna wrote:

> Signed-off-by: Miklos Vajna <vmiklos@frugalware.org>
> ---
>  gitweb/gitweb.perl |   10 +++++-----
>  1 files changed, 5 insertions(+), 5 deletions(-)
> 
> The plural form of "id" is "ids", not "id's", right?

It is a matter of some debate, actually. As an abbreviation, it should
rightly be "ID", and therefore "IDs". Most style manuals indicate that
no apostrophe should be used these days, unless it is an abbreviation
separated by dots (e.g., "I.D.'s").

Some disagree, and some indicate that you should use an apostrophe where
it may be visually more clear (for example, in single-letter
abbreviations like "A's").

There is a nice summary of some style guides here:

  http://answers.google.com/answers/threadview?id=499296

Honestly, for such an informal bit of text as a code comment, I'm not
sure it is worth nit-picking the grammar (e.g., we should be
writing SHA-1 everywhere, and we obviously don't). I'll let Shawn decide
whether he wants to apply or not.

-Peff

```

## Miklos Vajna, 2009-09-27 08:54

Subject: Re: [PATCH] gitweb: fix spelling errors in comments
Message-ID: <20090927085412.GS32702@genesis.frugalware.org>
URL: https://gitlist.dev/e/20090927085412.GS32702%40genesis.frugalware.org
In-Reply-To: <20090927083507.GA25891@coredump.intra.peff.net>

```
On Sun, Sep 27, 2009 at 04:35:07AM -0400, Jeff King <peff@peff.net> wrote:
> > The plural form of "id" is "ids", not "id's", right?
> 
> It is a matter of some debate, actually. As an abbreviation, it should
> rightly be "ID", and therefore "IDs". Most style manuals indicate that
> no apostrophe should be used these days, unless it is an abbreviation
> separated by dots (e.g., "I.D.'s").
> 
> Some disagree, and some indicate that you should use an apostrophe where
> it may be visually more clear (for example, in single-letter
> abbreviations like "A's").
> 
> There is a nice summary of some style guides here:
> 
>   http://answers.google.com/answers/threadview?id=499296
> 
> Honestly, for such an informal bit of text as a code comment, I'm not
> sure it is worth nit-picking the grammar (e.g., we should be
> writing SHA-1 everywhere, and we obviously don't). I'll let Shawn decide
> whether he wants to apply or not.

As a non-native I did not know to resolve "id's" to "id is" or "id has",
and once I figured it out, I thought about sending a patch.

Though, if that helps, I can resend it with "Blobs defined by
non-textual hash IDs can be cached" to be more readable.

```
