Take the 2-minute tour ×
TeX - LaTeX Stack Exchange is a question and answer site for users of TeX, LaTeX, ConTeXt, and related typesetting systems. It's 100% free, no registration required.

An easy way out would be to just texdoc the package name, but almost everyone knows that this does not apply to all packages. Some examples:

  • I didn't know there was a usrguide
  • There is an lshort.pdf but I cannot texdoc lshort
  • tikz is frequently mentioned in the TeX community but I need to texdoc pgfmanual

Where do I get a list (and descriptions, and possibly a search function) of all possible texdoc's in my installation? Yes, there is the MiKTeX Package Manager and the MacTeX TeX Live Utility, but as I've said, the package name or the PDF filename isn't necessarily the texdoc name.

share|improve this question
3  
texdoc tikz and texdoc lshort do work (at least in TeX Live 2010). –  Caramdir Oct 21 '10 at 0:24
    
See texdoc texdoc for documentation on texdoc itself –  Kit Dec 31 '10 at 2:51
1  
type texdoctk at commandline/terminal to get TeX documentation browser on TeXLive distro to search by keyword –  texenthusiast Apr 9 '13 at 12:35
add comment

5 Answers 5

up vote 11 down vote accepted

First of all, it must be noticed that texdoc is not the same under TeX live and MikTeX. Under MikTeX, the real command for searching documentation is mthelp which has a different behaviour and different options. The following comments are about TeX Live's version of texdoc.

The simple form texdoc <filename> should always find .pdf if it exists. Additionally, starting with version 0.70 (first available in TL2009 updates), the new form texdoc <tlpkgname> finds all documentation in the TeX Live package named (which is usually the same as the CTAN name, but not always) and texdoc <ltxpkgname> finds all documentation in the TeX Live package containing <ltxpkgname>.sty or <ltxpkgname>.cls if one of them exists. Obviously, if the argument to texdoc is both a TeX Live package name, a LaTeX package name, and the name of a pdf file, all results are returned. By the way, remember to use texdoc -l as Caramdir commented if you want to see all results and not just the first one.

This should answer your preamble "An easy way out would be to just texdoc the package name, but almost everyone knows that this does not apply to all packages.": now it does apply to all packages, at least for recent TeX Live.

For the actual question (list of all documentation files in your installation) here are two partial answers (partial in that they may list documentation that is not actually present in your local installation):

  1. TeX Live ships a list of all (html and pdf) documentation files sorted by TeX Live package (or bundle) in doc.html at the root of your installation (typically /usr/local/texlive/2010/doc.html);
  2. The by topic page of the TeX Catalogue Online is probably much more usable than a long flat list. For example, usrguide is mentioned under "Reference and Manuals -> LaTeX Documentation by the LaTeX3 Project".
share|improve this answer
add comment

Usually you get the manual by writing texdoc <pkg> where <pkg> is the CTAN name. So if you're interested in LaTeX packages, a good start would be the output of

ls `kpsewhich --var-value=TEXMFDIST`/doc/latex

Not sure how useful it will be for you though — on my TeX Live 2010 system that produces 1255 unique names; certainly too many to trawl through!

share|improve this answer
add comment

I usually google the package name before trying texdoc. It's more forgiving.

share|improve this answer
add comment

kpsewhich -var-value TEXDOCS gives a list of all of the places texdoc will search for pdfs.

You can get a list of all of the pdfs doing something like this.

for i in $(find $(kpsewhich -var-value TEXDOCS|sed -e 's/[{}!]//g;s/,/ /g') -name '*.pdf' 2>/dev/null); do basename $i;done|sort|uniq

It's a bit slow to sort. Or you can remove the for loop altogether and just use the find command to print out the entire path for each file.

share|improve this answer
add comment

If your distribution is MiKTeX you can use mthelp <package>. That will list all the installed documentation for <package>. For example mthelp pgf will list pgfmanual.pdf as one of the documents coming with the pgf bundle.

Otherwise you will need to browse the doc branch of your texmf directory or search CTAN for information.

share|improve this answer
1  
For TeX Live, one can use texdoc -l pgf. –  Caramdir Oct 21 '10 at 0:25
    
I have just installed lshort-english through the MiKTeX Package Manager. I have tried all combinations of texdoc, the -l option, and lshort or even lshort-english. It still won't give me the documentation. Well, lshort can be googled easily, I'm just using it as an example. Is there something wrong with my installation? –  Kit Oct 28 '10 at 0:19
    
Try mpm --print-package-info=lshort-english –  Martin Heller Oct 28 '10 at 3:21
add comment

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.