Closed VincenzoLaSpesa closed 3 years ago
On windows there is still the issue of the wrong encoding if the sources use some unicode characters. With this I exposed the encoding parameter to the MarkdownPP class and now I can call it with:
encoding
MarkdownPP
MarkdownPP(input=infile, modules=['include', 'toc'], output=outfile, encoding="UTF8")
If no encoding is provided it's defaulted to sys.getdefaultencoding()
sys.getdefaultencoding()
It was a quick fix I needed for one of my project, I'm open to any suggestion for writing it better.
On windows there is still the issue of the wrong encoding if the sources use some unicode characters. With this I exposed the
encoding
parameter to theMarkdownPP
class and now I can call it with:MarkdownPP(input=infile, modules=['include', 'toc'], output=outfile, encoding="UTF8")
If no encoding is provided it's defaulted to
sys.getdefaultencoding()
It was a quick fix I needed for one of my project, I'm open to any suggestion for writing it better.