[OS X TeX] citep and citet did not work in MacOSX-TeXShop

Herbert Schulz herbs at wideopenwest.com
Mon Feb 23 01:24:47 CET 2009


On Feb 22, 2009, at 5:50 PM, kchang wrote:

>
>
>
>
> %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
> Dear all,
> Thanks all of your suggestions which are very helpful!!
>
> Overall, I solved the problem. Here is the code works fine right  
> now. (Well,
> remember to run the "BibTex compiler" first and then "LaTex compiler")
>
> \documentclass[10pt]{article}
> \usepackage{natbib}
> %\usepackage[sort&compress,square,comma,authoryear]{natbib}
> \bibpunct{(}{)}{;}{a}{,}{,}
> \newcommand{\BibTeX}{{\sc Bib}\TeX}
> :
> :
> \begin{document}
> :
> :
> The carbon budget in soils is three times larger than the atmosphere  
> and
> soils have the potential to store additional carbon\citep{Campbell: 
> 1993dw},
> especially for properly managed agricultural lands\citet{Janzen: 
> 1998fc}.
> :
> :
>
> \bibliographystyle{plainnat}
> \bibliography{sample}
> \end{document}
>
> %%%%%%%%%%%%%%%%%%%%%
> Here is my bib file looks like: (a part of the bib file)
> @article{Paustian:2000zw,
> 	Author = {Paustian, K. and Six, J. and Elliott, E. T. and Hunt, H.  
> W.},
> 	Date-Added = {2009-01-12 18:40:15 -0500},
> 	Date-Modified = {2009-01-12 18:40:16 -0500},
> 	Journal = {Biogeochemistry},
> 	Number = {1},
> 	Pages = {147-163},
> 	Title = {Management options for reducing CO2 emissions from  
> agricultural
> soils},
> 	Volume = {48},
> 	Year = {2000}}
>


Howdy,

And now that things are working here's a nice way to automate the  
process of compiling, running bibtex (and/or makeindex) and then  
multiple compiles to resolve the references. It uses latexmk (included  
in TeXShop's ~/Library/TeXShop/bin/ directory) to automatically do all  
the processing necessary. Look at the pdf document in ~/Library/ 
TeXShop/Engines/Inactive/Latexmk/ for instructions on how to activate  
the engine files also found in the directory (basically move the  
engine files into ~/Library/TeXShop/Engines, two directories up the  
chain). Then place the line

%%!TEX TS-program = pdflatexmk

at the top of your tex source file and Typeset (Cmd-T) will do all of  
the necessary processing for you.

Hope this helps.

Good Luck,
Herb Schulz
(herbs at wideopenwest dot com)






More information about the macostex-archives mailing list