gpt4 book ai didi

templates - Pandoc 用户数据目录

转载 作者:行者123 更新时间:2023-12-02 04:37:55 24 4
gpt4 key购买 nike

我想在 Pandoc 中使用自定义 latex 模板。

我关注了instructions (--data-dir) 但后来我无法在我的 Mac 上找到用户数据目录,正如 here 所解释的那样.

所以我手动创建了 .pandoc/templates 文件夹,将我的模板放入 ~/.pandoc/templates , 运行 pandoc input.md --template=mytemplate.latex -o output.pdf
这就是我得到的

pandoc: Could not find data file /usr/local/Cellar/pandoc/1.18/share/x86_64-osx-ghc-8.0.1/pandoc-1.18/data/templates/mytemplate.latex

我可以轻松地将我的模板移动到该文件夹​​中,但我很确定这不是正确的方法,只要我升级到 v.1.19 后它就会停止工作。

最佳答案

好的,解决了。由于某种原因,它无法读取我的模板文件。

相反,我编辑了 pandoc -D latex > ~/.pandoc/templates/default.latex 的模板。生成并将其重命名为 mytemplate.latex。

它现在正在工作。

关于templates - Pandoc 用户数据目录,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/40390667/

24 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com