Welcome to mirror list, hosted at ThFree Co, Russian Federation.

git.kernel.org/pub/scm/git/git.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorKevin Cernekee <cernekee@gmail.com>2011-03-17 01:34:13 +0300
committerJunio C Hamano <gitster@pobox.com>2011-03-17 02:18:58 +0300
commit6affdbe677c4b2b8547bd9aa471464dd31a94a1c (patch)
treef71718b55df68708d4eea5f437599481ec3f93ca /builtin
parent1d679de58e886e134c5569c542667a08f0faedd6 (diff)
gitweb: highlight: replace tabs with spaces
Consider the following code fragment: /* * test */ vim ":set list" mode shows that the first character on each line is a tab: ^I/*$ ^I * test$ ^I */$ By default, the "highlight" program will retain the tabs in the HTML output: $ highlight --fragment --syntax c test.c <span class="hl com">/*</span> <span class="hl com"> * test</span> <span class="hl com"> */</span> vim list mode: ^I<span class="hl com">/*</span>$ <span class="hl com">^I * test</span>$ <span class="hl com">^I */</span>$ In gitweb, this winds up looking something like: 1 /* 2 * test 3 */ I tried both Firefox and Opera and saw the same behavior. The desired output is: 1 /* 2 * test 3 */ This can be accomplished by specifying "--replace-tabs=8" on the highlight command line. Signed-off-by: Kevin Cernekee <cernekee@gmail.com> Acked-by: John 'Warthog9' Hawley <warthog9@eaglescrag.net> Signed-off-by: Junio C Hamano <gitster@pobox.com>
Diffstat (limited to 'builtin')
0 files changed, 0 insertions, 0 deletions