Hello,

Under Python 3.2.2, Pygments 1.4 raises an following error when the
encoding option is specified on its command line, as reported here:

https://bitbucket.org/birkenfeld/pygments-main/issue/691/utf-8-encoding-via-pygmentize-raises

To work around this error in AsciiDoc 8.6.6, I edited the following:

/etc/asciidoc/filters/source/source-highlight-filter.conf line 56

-ifdef::pygments[source-style=template="source-highlight-block",presubs=(),postsubs=("callouts",),posattrs=("style","language","src_numbered"),filter="pygmentize
 -f html -l {language} {src_numbered?-O linenos=table} {encoding?-O 
encoding={encoding}}"]
+ifdef::pygments[source-style=template="source-highlight-block",presubs=(),postsubs=("callouts",),posattrs=("style","language","src_numbered"),filter="pygmentize
 -f html -l {language} {src_numbered?-O linenos=table}"]

I hope this helps someone.  Cheers.

-- 
All men know the utility of useful things;
but they do not know the utility of futility.
                -- Chuang-tzu

Attachment: signature.asc
Description: PGP signature

Reply via email to