
我使用 RStudio 和 Pandoc 将我在 markdown 中创建的文档输出为 PDF。Pandoc 总是使用逐字环境转换 markdown 中的代码块。有人知道如何将默认转换环境从逐字切换到列表吗?
答案1
2011 年发布的 pandoc 1.8[1] 版本添加了一个--listings
选项“使用 LaTeX 代码块的 listings 包”来代替在 pandoc 中进行高亮显示。参考手册:https://pandoc.org/MANUAL.html。
我使用 RStudio 和 Pandoc 将我在 markdown 中创建的文档输出为 PDF。Pandoc 总是使用逐字环境转换 markdown 中的代码块。有人知道如何将默认转换环境从逐字切换到列表吗?
2011 年发布的 pandoc 1.8[1] 版本添加了一个--listings
选项“使用 LaTeX 代码块的 listings 包”来代替在 pandoc 中进行高亮显示。参考手册:https://pandoc.org/MANUAL.html。