{"thread":{"id":"32009","subject":"Re: [PATCH] gitweb.perl: fix %highlight_ext mappings","startedAt":"2012-11-02T21:12:26Z","lastAt":"2012-11-04T17:44:22Z","messageCount":3,"participants":["Jeff King","rh"],"isPatch":true,"patchVersion":1,"patchTotal":null},"messages":[{"id":"299192","messageId":"20121102141226.643a96e61b8bf383428c5287@lavabit.com","threadId":"32009","inReplyTo":null,"subject":"[PATCH] gitweb.perl: fix %highlight_ext mappings","fromName":"rh","fromEmail":"richard_hubbe11@lavabit.com","sentAt":"2012-11-02T21:12:26Z","receivedAt":"2012-11-02T21:12:26Z","isPatch":true,"sender":{"key":"richard_hubbe11@lavabit.com","avatar":null},"body":"\nThe previous change created a dictionary of one-to-one elements when\nthe intent was to map mutliple related types to one main type.\ne.g. bash, ksh, zsh, sh all map to sh since they share similar syntax\nThis makes the mapping as the original change intended.\n\nSigned-off-by: rh <richard_hubbe11@lavabit.com>\n\ndiff --git a/gitweb.cgi.orig b/gitweb.cgi\nindex 060db27..155b238 100755\n--- a/gitweb.cgi.orig\n+++ b/gitweb.cgi\n@@ -246,19 +246,19 @@ our %highlight_basename = (\n \t'Makefile' => 'make',\n );\n # match by extension\n+\n our %highlight_ext = (\n \t# main extensions, defining name of syntax;\n \t# see files in /usr/share/highlight/langDefs/ directory\n-\tmap { $_ => $_ }\n-\t\tqw(py c cpp rb java css php sh pl js tex bib xml awk bat ini spec tcl sql make),\n+\t(map { $_ => $_ } qw(py rb java css js tex bib xml awk bat ini spec tcl sql)),\n \t# alternate extensions, see /etc/highlight/filetypes.conf\n-\t'h' => 'c',\n-\tmap { $_ => 'sh'  } qw(bash zsh ksh),\n-\tmap { $_ => 'cpp' } qw(cxx c++ cc),\n-\tmap { $_ => 'php' } qw(php3 php4 php5 phps),\n-\tmap { $_ => 'pl'  } qw(perl pm), # perhaps also 'cgi'\n-\tmap { $_ => 'make'} qw(mak mk),\n-\tmap { $_ => 'xml' } qw(xhtml html htm),\n+\t(map { $_ => 'c'   } qw(c h)),\n+\t(map { $_ => 'sh'  } qw(sh bash zsh ksh)),\n+\t(map { $_ => 'cpp' } qw(cpp cxx c++ cc)),\n+\t(map { $_ => 'php' } qw(php php3 php4 php5 phps)),\n+\t(map { $_ => 'pl'  } qw(pl perl pm)), # perhaps also 'cgi'\n+\t(map { $_ => 'make'} qw(make mak mk)),\n+\t(map { $_ => 'xml' } qw(xml xhtml html htm)),\n );\n \n # You define site-wide feature defaults here; override them with\n\n"},{"id":"202515","messageId":"20121104134841.GC31623@sigill.intra.peff.net","threadId":"32009","inReplyTo":"20121102141226.643a96e61b8bf383428c5287@lavabit.com","subject":"Re: [PATCH] gitweb.perl: fix %highlight_ext mappings","fromName":"Jeff King","fromEmail":"peff@peff.net","sentAt":"2012-11-04T13:48:41Z","receivedAt":"2012-11-04T13:48:41Z","isPatch":true,"sender":{"key":"peff@peff.net","avatar":"https://avatars.githubusercontent.com/u/45925?v=4"},"body":"On Fri, Nov 02, 2012 at 02:12:26PM -0700, rh wrote:\n\n> The previous change created a dictionary of one-to-one elements when\n> the intent was to map mutliple related types to one main type.\n> e.g. bash, ksh, zsh, sh all map to sh since they share similar syntax\n> This makes the mapping as the original change intended.\n> \n> Signed-off-by: rh <richard_hubbe11@lavabit.com>\n> \n> diff --git a/gitweb.cgi.orig b/gitweb.cgi\n> index 060db27..155b238 100755\n> --- a/gitweb.cgi.orig\n> +++ b/gitweb.cgi\n\nClose on the format. There should be a \"---\" after the sign-off but\nbefore the diff. I can fix it up locally (and the patch looks good to\nme).\n\nHowever, one final thing: the point of the sign-off is to indicate that\nyou are legally OK to release the code under the DCO. For that reason,\nwe usually require a real name (not rh). I can guess at your real name\nfrom your email, but I'd rather be sure. Can you provide it?\n\n-Peff\n"},{"id":"299193","messageId":"20121104094422.7273cd146654f06ccb1b2baa@lavabit.com","threadId":"32009","inReplyTo":"20121104134841.GC31623@sigill.intra.peff.net","subject":"Re: [PATCH] gitweb.perl: fix %highlight_ext mappings","fromName":"rh","fromEmail":"richard_hubbe11@lavabit.com","sentAt":"2012-11-04T17:44:22Z","receivedAt":"2012-11-04T17:44:22Z","isPatch":true,"sender":{"key":"richard_hubbe11@lavabit.com","avatar":null},"body":"On Sun, 4 Nov 2012 08:48:41 -0500\nJeff King <peff@peff.net> wrote:\n\n> On Fri, Nov 02, 2012 at 02:12:26PM -0700, rh wrote:\n> \n> > The previous change created a dictionary of one-to-one elements when\n> > the intent was to map mutliple related types to one main type.\n> > e.g. bash, ksh, zsh, sh all map to sh since they share similar\n> > syntax This makes the mapping as the original change intended.\n> > \n> > Signed-off-by: rh <richard_hubbe11@lavabit.com>\n> > \n> > diff --git a/gitweb.cgi.orig b/gitweb.cgi\n> > index 060db27..155b238 100755\n> > --- a/gitweb.cgi.orig\n> > +++ b/gitweb.cgi\n> \n> Close on the format. There should be a \"---\" after the sign-off but\n> before the diff. I can fix it up locally (and the patch looks good to\n> me).\n> \n> However, one final thing: the point of the sign-off is to indicate\n> that you are legally OK to release the code under the DCO. For that\n> reason, we usually require a real name (not rh). I can guess at your\n> real name from your email, but I'd rather be sure. Can you provide it?\n\nRoger wilco. Resubmitting. \nThanks for the time and consideration.\n> \n> -Peff\n\n\n-- \n\n\n"}]}