Document ClassesChecking the version of a package

Information and discussion about specific document classes and how to create your own document classes.
Post Reply
curiouslearn
Posts: 105
Joined: Fri Nov 30, 2007 11:32 pm

Checking the version of a package

Post by curiouslearn »

Hi,

I have Basictex installed on Mac OS X Leopard. I was wondering if there is a way to check whether the TikZ/PGF package that I have is the latest version. Is there a way to do that?

Also, I did not install it manually by copying the style file in library/texmf/tex/latex folder. Hence, if I find that it is not the latest version, how do I update it?

Thanks very much.

Recommended reading 2024:

LaTeXguide.org • LaTeX-Cookbook.net • TikZ.org

NEW: TikZ book now 40% off at Amazon.com for a short time.

User avatar
Juanjo
Posts: 657
Joined: Sat Jan 27, 2007 12:46 am

Checking the version of a package

Post by Juanjo »

I think that BasicTeX comes with tlmgr (TeX Live Manager), which you can use to check updates and install missing packages. The full documentation is here. According to it, to see which packages need an update, open Terminal and type:

Code: Select all

tlmgr update --list
To update pgf/tikz:

Code: Select all

sudo tlmgr update pgf
There is also a GUI version of tlmgr which works using the X11 interface.

Finally, each time you compile, the log file registers which files are read during that process as well as related information (like versions). If you add the command \listfiles to the preamble, you'll get a complete list of such files in the log file and the console.
The CTAN lion is an artwork by Duane Bibby. Courtesy of www.ctan.org.
curiouslearn
Posts: 105
Joined: Fri Nov 30, 2007 11:32 pm

Checking the version of a package

Post by curiouslearn »

Thanks very much, Juanjo. That worked like a charm. I found that there are a few packages that need an update. Is there a way to get all of them updated with one command instead of updating each individually.

Also, I found that the version to which tlmgr updated my pgf package is not the very latest on the texexample site. I understand that there would obviously be a lag between the latest update and when it gets included in the distribution. My question is that if I manually download and install it in the my library/texmf/tex/latex/ then which version is used when the file is being compiled...the one I installed or the one that came with the distribution.

Thanks again.
User avatar
Juanjo
Posts: 657
Joined: Sat Jan 27, 2007 12:46 am

Checking the version of a package

Post by Juanjo »

curiouslearn wrote: I found that there are a few packages that need an update. Is there a way to get all of them updated with one command instead of updating each individually.
sudo tlmgr update --all
curiouslearn wrote: My question is that if I manually download and install it in the my library/texmf/tex/latex/ then which version is used when the file is being compiled...the one I installed or the one that came with the distribution.
Files in ~Library/texmf are read first. You can easily check that. Before installing anything there, compile a tex file and look in the log file for the package version. Then install, look again and compare.
The CTAN lion is an artwork by Duane Bibby. Courtesy of www.ctan.org.
curiouslearn
Posts: 105
Joined: Fri Nov 30, 2007 11:32 pm

Re: Checking the version of a package

Post by curiouslearn »

Thanks very much Juanjo.
Post Reply