【Mac OS】LaTeX(MacTeX) 用.bib文件写引用的一些问题

1. 编译 .bib时出现  Can't open file name 'XXXXX.aux' 错误

解决方案:

来源:https://tex.stackexchange.com/questions/166831/cant-open-reference-aux

Let's suppose your references are written in a file called 'ref.bib' with entries like:

@article{latex1977,
    title={How to use latex},
    author={John Smith},
    journal={Journal of Latex},
    pages={1--50},
    volume={39},
    year={1977}
}

Now in your main file say 'main.tex' you have to have something like:

\documentclass{article}
\begin {document}

...
\cite{latex1977}
...

\bibliography{ref}
\bibliographystyle{plain}

\end{document}

To compile your document do this steps:

1. compile 'main.tex' using latex or pdflatex => this step will generate main.aux file

2. compile 'main.aux' (NOT 'ref.bib') using bibtex 

3. compile twice 'main.tex' using latex or pdflatex

=========================================================

=========================================================

如果不好使,可以试试这个神奇方法试一下(我用的MacTex ,系统10.15.5)

补一个Mactex的下载地址:http://www.tug.org/mactex/

step1:确定已经建立了正确的.bib文件,路径也对(和.tex文件在一个路径下)

step2:检查下名字

 \bibliography{XXX} 这条语句中的XXX和XXX.bib文件是不是一个名字

(应该是同一个名字,不是就调一下吧)
举例子:ref.bib
那么,语句应该是\bibliography{ref}

step3:打开.tex文件,先用LaTeX 执行下"排版"操作,生成.aux文件和一大沓子其他的(重要的是这个.aux)

              如图         

             (第二个选项框选LaTeX,点 "排版" 按钮)

step4:还是这个.tex文件,第二个选项框选BibTeX,再次点“排版”按钮

              如图          

             (第二个选项框选BibTeX,点 "排版" 按钮)

step5:还是这个.tex文件,第二个选项框选LaTeX,再次点“排版”按钮

 

然后就可以啦,那个引用就出来了! ^▽^ ~

  

  • 0
    点赞
  • 2
    收藏
    觉得还不错? 一键收藏
  • 0
    评论
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值