如何在markdown/pandoc中移动书目 [英] How to move the bibliography in markdown/pandoc

查看:96
本文介绍了如何在markdown/pandoc中移动书目的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我目前正在写学士论文,我的指导老师希望我将附录放在参考书目之后,但markdown/pandoc默认将参考文献放在最后. 我在 http://yihui.name/knitr/demo/pandoc/中阅读了说明,试图使用include-after-body=FILE命令在文档末尾放置一个单独的.rmd文件 我的代码如下:

I'm currently writing my bachelor thesis and my instructor wants me to put my appendix after the bibliography but markdown/pandoc puts the references at the end by default. I read the instructions at http://yihui.name/knitr/demo/pandoc/ and tried to use the include-after-body=FILE command to put a separate .rmd file at the end of the document My code looks like this:

```{r, echo=FALSE, warning=FALSE, message=FALSE}
library(knitr)
pandoc('thesis.rmd', format="latex")
```

,并提供选项:

<!--pandoc
t: latex
include-after-body: appendix.rmd
o: output.pdf
-->

其中appendix.rmd是单独的附录文件.

Where appendix.rmd is the separate appendix file.

点击转换pdf后,该行后出现错误,导致进程卡住 executing pandoc --include-after-body=appendix.rmd -o thesis.pdf -f markdown -t latex -o thesis.pdf "thesis.utf8md"

After klicking on convert pdf, the process gets stuck with an error after the line executing pandoc --include-after-body=appendix.rmd -o thesis.pdf -f markdown -t latex -o thesis.pdf "thesis.utf8md"

错误是:

pandoc.exe: Error producing PDF from TeX source.

代码是否存在问题,或者是否有其他方法可以从文档末尾删除参考书目?

Is there something wrong with the code or is there some other method to remove the bibliography from the end of the document?

推荐答案

还有另一种解决方案:

<div id="refs"></div>

它使您可以将引用放置在任意位置.

It lets you put the references wherever you want.

这篇关于如何在markdown/pandoc中移动书目的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆