我正在使用 biblatex 和 backend=biber 来编写文档。为简单起见,我在参考书目中的某些条目中使用“id”,但在其他条目中则不使用。我遇到的问题是,带有“id”的条目事后会被排序,尽管它们应该按出现顺序排序(sorting=none)
我正在使用 biber 版本:2.11
换句话说,在下面的例子中,我得到的是,
This should appear as 1: [2]
and this should appear as 2: [1]
当应该
This should appear as 1: [1]
and this should appear as 2: [2]
有任何想法吗?
我的例子.tex
\documentclass[11pt,a4paper]{article}
\usepackage[backend=biber, sorting=none, style=numeric-comp, firstinits=true, maxnames=4, uniquename=false]{biblatex}
\addbibresource{example.bib}
\begin{document}
This should appear as 1:~\cite{id:peskin}
and this should appear as 2:~\cite{Ellis:1991qj}
\end{document}
还有我的 example.bib 文件:
@book{Peskin:1995ev,
ids = {id:peskin},
author = {Peskin, Michael E. and Schroeder, Daniel V.},
title = {An Introduction to quantum field theory},
publisher = {Addison-Wesley},
address = {Reading, USA},
year = {1995},
url = {http://www.slac.stanford.edu/~mpeskin/QFT.html},
isbn = {9780201503975},
SLACcitation = {%%CITATION= INSPIRE-407703;%%}
}
@book{Ellis:1991qj,
author = {Ellis, R. Keith and Stirling, W. James and Webber, B. R.},
title = {QCD and collider physics},
publisher = {Cambridge University Press},
year = {1996},
pages = {1-435},
SLACcitation = {%%CITATION = CMPCE,8,1;%%}
}
答案1
这是 Biber 必须运行两次才能获得预期结果的罕见情况之一。编译将运行
- 乳胶
- 比贝尔
- 乳胶
- 比贝尔
- 乳胶
- 乳胶
额外运行是必要的,因为 id 别名需要正确解析。
事实上,在第一次 Biber 运行之后,第一次运行 LaTeX 会要求运行第二次 Biber,但如果你运行 LaTeX,那个警告就会消失……我为此开了一张票(https://github.com/plk/biblatex/issues/778),但我不确定这里可以做什么。