User installation of additional TeX/LaTeX classes and styles
When you are the sysadmin, you can simply drop the new class/style files under the system TeX path (e.g. /usr/share/texmf/tex/) and run 'texhash' to have them automatically picked up. But what do you do when you are just a regular user?
TeX/LaTeX looks at the TEXINPUTS environment variable to look for additional locations to search for included/referenced files. Therefore, new classes/styles can be easily added as follows:
The '.' ensures that the working directory is included in the search path. The double-'//' tells bash to also include files in subdirectories of '$HOME/tex' recursively.
New BibTeX files can also be added locally in a similar fashion. The variables to set are then BSTINPUTS and BIBINPUTS.
The environment variable to set for MakeIndex styles is: INDEXSTYLE.
Source: AstroNat - Installation at The Smithsonian/NASA Astrophysics Data System
UPDATE [16 July 2009] The Kpathsea manual provides a wealth of information about usable environment variables.
TeX/LaTeX looks at the TEXINPUTS environment variable to look for additional locations to search for included/referenced files. Therefore, new classes/styles can be easily added as follows:
- Create a directory for the files:
$ mkdir -p $HOME/tex/latex
- Place the new class files into that folder (each class can be in its own directory and contain subdirectories):
$ cp -a fancy-class $HOME/tex/latex/
- Export the TEXINPUTS variable and also add it to your $HOME/.bash_profile:
$ export TEXINPUTS=.:$HOME/tex/latex//:$TEXINPUTS
The '.' ensures that the working directory is included in the search path. The double-'//' tells bash to also include files in subdirectories of '$HOME/tex' recursively.
New BibTeX files can also be added locally in a similar fashion. The variables to set are then BSTINPUTS and BIBINPUTS.
The environment variable to set for MakeIndex styles is: INDEXSTYLE.
Source: AstroNat - Installation at The Smithsonian/NASA Astrophysics Data System
UPDATE [16 July 2009] The Kpathsea manual provides a wealth of information about usable environment variables.