[OS X TeX] Command-line fun
Bruno Voisin
bvoisin at mac.com
Mon Jan 15 15:21:27 CET 2007
I've been looking for a way to clean up the texmf.local directory (in
gwTeX) and texmf-local directory (in MacTeX) after customizing it
manually in the Finder. By cleaning up I mean:
(1) Set user and group to the same values as for the other texmf
trees. Meaning, with the default configuration of gwTeX: user to root
and group to wheel.
(2) Set permissions to the same values as for the other texmf trees.
Meaning, again with the default configuration of gwTeX: drwxr-xr-x
for directories and -rw-r--r-- for files.
(3) Erasing all the invisible .DS_Store files created here and there
by the Finder.
Based on a solution to (2) posted here long ago by Maarten Sneep,
I've resorted to the following one-liners, using gwTeX as an example:
- Task (1):
sudo chown -Rh root:wheel /usr/local/gwTeX/texmf.local
- Task (2):
sudo find /usr/local/gwTeX/texmf.local -type d -exec chmod 755 {} \;
sudo find /usr/local/gwTeX/texmf.local -type f -exec chmod 644 {} \;
- Task (3):
sudo find /usr/local/gwTeX/texmf.local -name ".DS_Store" -delete
This seems to work well, but being not a command-line specialist (to
be honest I'm pretty scared every time I have to go to the command-
line, and even more scared when I'm about to use sudo) I'm suspecting
something in the above could have unwanted side effects or compromise
the new TeXDist structure.
Could somebody command-line-savvy confirm the above is safe, or
correct whatever silly mistake I may have made?
BTW, I just noticed that in a TeXLive-2006 MacTeX install the texmf-
var directory and its content are writable by everybody:
theo0mc234:/usr/local/texlive/2006 brunovoisin$ ls -l
total 0
drwxr-xr-x 4 root wheel 136 Jan 4 03:24 bin
drwxr-xr-x 20 root wheel 680 Jan 11 17:20 texmf
drwxr-xr-x 8 root wheel 272 Jan 11 17:20 texmf-config
drwxr-xr-x 19 root wheel 646 Jan 11 17:20 texmf-dist
drwxr-xr-x 5 root wheel 170 Jan 4 03:24 texmf-doc
drwxrwxrwx 9 root wheel 306 Jan 11 17:20 texmf-var
theo0mc234:/usr/local/texlive/2006/texmf-dist brunovoisin$ cd texmf-var
theo0mc234:/usr/local/texlive/2006/texmf-var brunovoisin$ ls -l
total 8
drwxrwxrwx 3 root wheel 102 Jan 4 03:20 dvipdfm
drwxrwxrwx 3 root wheel 102 Jan 4 03:20 dvips
drwxrwxrwx 5 root wheel 170 Jan 4 03:20 fonts
-rw-rw-rw- 1 root wheel 1747 Jan 11 17:20 ls-R
drwxrwxrwx 5 root wheel 170 Jan 4 03:20 tex
drwxrwxrwx 80 root wheel 2720 Jan 11 16:38 web2c
drwxrwxrwx 3 root wheel 102 Jan 4 03:30 xdvi
Is this on purpose?
Bruno Voisin
------------------------- Helpful Info -------------------------
Mac-TeX Website: http://www.esm.psu.edu/mac-tex/
TeX FAQ: http://www.tex.ac.uk/faq
List Archive: http://tug.org/pipermail/macostex-archives/
List Reminders & Etiquette: http://www.esm.psu.edu/mac-tex/list/
More information about the macostex-archives
mailing list