about summary refs log tree commit diff stats
diff options
context:
space:
mode:
-rwxr-xr-xfilters/syntax-highlighting.py4
1 files changed, 2 insertions, 2 deletions
diff --git a/filters/syntax-highlighting.py b/filters/syntax-highlighting.py index 1ca4108..5888b50 100755 --- a/filters/syntax-highlighting.py +++ b/filters/syntax-highlighting.py
@@ -30,8 +30,8 @@ from pygments.lexers import guess_lexer_for_filename
30from pygments.formatters import HtmlFormatter 30from pygments.formatters import HtmlFormatter
31 31
32 32
33sys.stdin = io.TextIOWrapper(sys.stdin.buffer, encoding='utf-8') 33sys.stdin = io.TextIOWrapper(sys.stdin.buffer, encoding='utf-8', errors='replace')
34sys.stdout = io.TextIOWrapper(sys.stdout.buffer, encoding='utf-8') 34sys.stdout = io.TextIOWrapper(sys.stdout.buffer, encoding='utf-8', errors='replace')
35data = sys.stdin.read() 35data = sys.stdin.read()
36filename = sys.argv[1] 36filename = sys.argv[1]
37formatter = HtmlFormatter(style='pastie') 37formatter = HtmlFormatter(style='pastie')