git/list[1] front-page[2] threads[3] people[4] search[5] about
 

Re: [PATCH] gitweb: Strip non-printable characters from syntax highlighter output

From
Christopher M. Fuhrman <cfuhrman@panix.com>
Date
Sep 16, 2011, 18:11 UTC
Message-ID
<alpine.NEB.2.01.1109161050080.2073@vc75.vc.panix.com>
In-Reply-To
<201109161441.58946.jnareb@gmail.com>
Howdy,
On Fri, 16 Sep 2011 at 5:41am, Jakub Narebski wrote:
Show 5 quoted lines
> The commit message is from Christopher, but I have replaced his solution
> of stripping non-printable characters via col(1) program by having gitweb
> strip characters not allowed in XML.
>
> Christopher, could you check that it fixes your issue?

After applying the patch, I tested it successfully against the following files:

 * linux.git : arch/ia64/kernel/unwind.c
 * git.git   : t/t3902-quoted.sh

Furthermore, I'm pleased to report that non en_US.UTF8 characters (e.g., Chinese hanzi) as found in t3902-quoted.sh are displayed properly when highlight is enabled.

Tested Web Browsers:
 * Safari (5.1 (6534.50)
 * Firefox 6.0.2 under Mac OS X Snow Leopard
 * Google Chrome 13.0.782.220 under OpenSuSE 11.4
>
>  gitweb/gitweb.perl |   14 +++++++++++++-
>  1 files changed, 13 insertions(+), 1 deletions(-)
>
Cheers!
-- 
Chris Fuhrman
cfuhrman@panix.com
Previous: Junio C Hamano
Message 10 of 10 in “gitweb: highlight: strip non-printable characters via col(1)”
  1. gitweb: highlight: strip non-printable characters via col(1)Christopher M. Fuhrman, Aug 22, 2011
  2. Junio C HamanoAug 22, 2011
  3. Jakub NarebskiAug 26, 2011
  4. Junio C HamanoAug 26, 2011
  5. Jakub NarebskiAug 26, 2011
  6. gitweb: Strip non-printable characters from syntax highlighter outputJakub Narebski, Sep 16, 2011
  7. Junio C HamanoSep 16, 2011
  8. Jakub NarebskiSep 16, 2011
  9. Junio C HamanoSep 16, 2011
  10. Christopher M. FuhrmanSep 16, 2011

Read the whole thread, see it on lore, or plain text.

$ cat FOOTERMessages come from the public archive at lore.kernel.org/git, fetched every hour. The front page is chosen and written each morning by an AI editor and can be wrong; the threads themselves are the record. About and API. For agents: an MCP server at https://gitlist.dev/mcp, and any thread, story or person page as Markdown by adding .md to its URL (or sending Accept: text/markdown). Details in /llms.txt.