Encoding Windows控制台上的pandoc输出乱码
我在开始使用Pandoc时遇到了一个问题:我设法在他们的网站上重复了这个示例,命令是:Encoding Windows控制台上的pandoc输出乱码,encoding,markdown,pandoc,Encoding,Markdown,Pandoc,我在开始使用Pandoc时遇到了一个问题:我设法在他们的网站上重复了这个示例,命令是: pandoc "Hello there," she said---and Sam didn't reply. Ctrl+Z 输出应为: <p>"Hello there," She said---and Sam didn't reply.</p> 然后我得到: <p>“She said”</p> “她说” 请注意,两个引
pandoc
"Hello there," she said---and Sam didn't reply.
Ctrl+Z
输出应为:
<p>"Hello there," She said---and Sam didn't reply.</p>
然后我得到:
<p>“She said”</p>
“她说”
请注意,两个引号变成了中文字符,这不是我想要的结果。
当我将包含英文引号的标记文件转换为pdf文件时,这个问题困扰着我。它们只是自动转换,我不知道如何处理…如果您使用的是
cmd
,请在调用pandoc之前尝试键入chcp 65001
。这将cmd上的编码设置为UTF-8
见:
- (如果您使用的是powershell,请参阅下一条注释)
pandoc
"She said"
Ctrl + Z
<p>“She said”</p>