I am currently trying to run some R code on a computing cluster but cannot run the install.packages function due to some weird firewall settings on my cluster. Since I am only using a few packages in my R code, I was hoping to avoid using the install.packages function by downloading and installing the packages manually. Note: I am aware that there is a way to avoid this issue by using an HTTP. How can I manually install a package on MiKTeX (Windows)? I’m using MiKTeX on Windows. My employer’s locked-down network blocks the application’s automatic installation function. I can take my laptop home and successfully install from there, but if I need a package in the middle of the day I’m stuck.
Active10 years ago
I'm fairly new to LaTeX, but have been using my own document template for a couple of years now to do basic typesetting. What I want to do is to add the pst-gantt package from PSTricks.
I have never installed a new package before, but want it available to all of my projects. For the sake of completeness, I am running OSX10.6 and use TeXShop to edit text, however am slowly switching over to TextEdit.
Anyway, I have googled and the results all say to use .dtx and .ins files (which I cannot find). If someone can give me some pointers as to what I need to install (do I need PSTricks first?) and how to go about doing it, that would be great.
Thanks
JackJack2,3731212 gold badges3939 silver badges7070 bronze badges
2 Answers
If you're using MacTeX 2008, pop open your terminal and type:
the package will be installed. If you have perl/TK installed, open your terminal and type:
There is also a native mac package manager for MacTeX that can be had from their website.
MicaMica13.8k44 gold badges3636 silver badges4040 bronze badges
The first thing to do would be to check if your distribution doesn't already provide a way to add the package to your TeX installation. You didn't say which distribution you used (MacTeX ? TeX Live ?) and that's actually the most important part. The editor you use for typing source files is unrelated, it's only the front-end to the actual TeX binaries and files.
To answer your second question, you do need core PSTricks macros in order to use any PSTricks-related package, so do that first; all the major distributions ship PSTricks, so first try to figure out how to install it (and maybe it's there already). There really should be a way to do so, so only try the steps in the next paragraphs if all else fails.
If installation is not possible via graphical applications shipped with your TeX distribution, you may have to install the files by hand. I outline the process briefly here, but you can read the manual for 'kpathsea' for more information (it's the library through which TeX and related programs find files). First identify the main directory where your TeX files resides; it's usually called texmf-[something]. In TeX Live it's /usr/local/texlive/[year]/texmf-dist by default; in MacTeX it should be somewhere under /Library/TeX/Distributions.
From there, look for a directory called texmf-local (or texmf.local, etc.); that's where you should drop the files; more precisely in texmf-local/tex/latex/pst-gantt. Then run 'texhash' from the command line in Terminal, and you should be done. The latter command may not be in your PATH environment variable, so you may have to set up this first.
Hope this helps.
Install Latex Miktex
Oh, and you don't need .dtx and .ins; they're just a LaTeXy way of packing all the files together for upstream distribution; what you really need is the .sty file, as well as, obviously, docs.
Arthur ReutenauerArthur Reutenauer2,49611 gold badge1212 silver badges1414 bronze badges