aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorVanya Sergeev <vsergeev@gmail.com>2014-06-30 09:59:39 +0200
committerAlberto Bertogli <albertito@blitiri.com.ar>2014-07-03 01:56:19 +0200
commiteb7cadd64faee9e654a9aee992d21d7bceb716ea (patch)
tree371a09f7d73a0cd053a18315fdd1d8cd09a66856
parent48a00cb460f0e5252e28a59d462e40d891b0b54d (diff)
downloadgit-arr-fork-eb7cadd64faee9e654a9aee992d21d7bceb716ea.zip
Enable line number anchors when using pygments HtmlFormatter
Signed-off-by: Vanya Sergeev <vsergeev@gmail.com>
-rw-r--r--utils.py4
1 files changed, 3 insertions, 1 deletions
diff --git a/utils.py b/utils.py
index 51141e4..46407bd 100644
--- a/utils.py
+++ b/utils.py
@@ -89,7 +89,9 @@ def colorize_blob(fname, s):
formatter = HtmlFormatter(encoding = 'utf-8',
cssclass = 'source_code',
- linenos = 'table')
+ linenos = 'table',
+ anchorlinenos = True,
+ lineanchors = 'line')
return highlight(s, lexer, formatter)