aboutsummaryrefslogtreecommitdiffstats
path: root/ui-diff.c
diff options
context:
space:
mode:
authorGravatar Stefan Tatschner <stefan@sevenbyte.org>2014-01-14 06:10:45 (JST)
committerGravatar Jason A. Donenfeld <Jason@zx2c4.com>2014-01-14 06:48:51 (JST)
commitceffeb5d52609a38c5d5d410456d796673fe8461 (patch)
treec262452378843ea97e893caf5866d3848553e380 /ui-diff.c
parenta52aaa90dab1d95f9df383d2cb3f7c428ab849fe (diff)
downloadcgit-ceffeb5d52609a38c5d5d410456d796673fe8461.zip
cgit-ceffeb5d52609a38c5d5d410456d796673fe8461.tar.gz
filters: Improved syntax-highlighting.py
- Switched back to python2 according to a problem in pygments with python3. With the next release of pygments this problem should be fixed. Issue see here: https://bitbucket.org/birkenfeld/pygments-main/issue/901/problems-with-python3 - Just read the stdin, decode it to utf-8 and ignore unknown signs. This ensures that even destroyed files do not cause any errors in the filter. - Improved language guessing: -> At first use guess_lexer_for_filename for a better detection of the used programming languages (even mixed cases will be detected, e.g. php + html). -> If nothing was found look if there is a shebang and use guess_lexer. -> As default/fallback choose TextLexer. Signed-off-by: Stefan Tatschner <stefan@sevenbyte.org>
Diffstat (limited to 'ui-diff.c')
0 files changed, 0 insertions, 0 deletions