[OS X TeX] Re: Some ideas LaTeX on iPad, iPhone, etc.

Ramón Figueroa-Centeno ramonf at hawaii.edu
Tue Mar 23 05:41:23 CET 2010


Let me reply my own question :)

Our goal is to have a folder such that any change to the folder will trigger
an execution of pdflatexmk on all the files within with suffix "tex" in the
folder. In my case I want the folder to be inside my DropBox folder, So I
assume my target folder is "~/DropBox/LaTeXMe". I assume that you have
TeXShop installed and Herb Schultz's pdflatexmk engine enabled (that is, you
moved ~/Library/TeXShop/Engines/Inactive/Latexmk/pdflatexmk.engine to

Here are the steps:

1. In a text editor create a bash script, which I did in ~/bin/latexme.sh,
that will create the folder if it does not exist, cd to it, and run
pdflatexmk on all the ".tex" files therein:



mkdir -p $LaTeXMeDir
cd $LaTeXMeDir
find . -type f -name '*.tex' -execdir $engine '{}' \;

3. Make sure the script is executable, e.g. type in the Terminal "chmod +x
~/bin/latexme.sh" (no quotations, of course).

2. In a text editor create a "Launch Agent" (say
~/Library/LaunchAgents/com.ramonfigueroacenteno.LaTeXMe.plist) to watch our
LaTeXMe folder for changes and trigger the script:

<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN"
<plist version="1.0">

4. Load your Launch Agent, e.g. "launchctl load
~/Library/LaunchAgents/com.ramonfigueroacenteno.LaTeXMe.plist" in the

Note that give that the script is very short one could easily inbed it the
Launch Agent, but I prefer it this way since I can more easily tweak the
script if needed.

That's it!



View this message in context: http://n2.nabble.com/Some-ideas-LaTeX-on-iPad-iPhone-etc-tp4781323p4782400.html
Sent from the MacOSX-TeX mailing list archive at Nabble.com.

More information about the macostex-archives mailing list