[OS X TeX] latexdb & texshop

Herbert Schulz herbs at wideopenwest.com
Thu Oct 13 02:31:38 CEST 2005


On Oct 12, 2005, at 6:12 PM, Ingo Reich wrote:

> Hi,
> I'd like to use latexdb from within texshop. (latexdb is a script  
> based on python that enables one to connect to mySQL-databases from  
> within a latex-file: http://privat.hgesser.com/software/latexdb/).  
> I tried to adapt one of Claus Gerhardts Scripts and came up with  
> the one below. The applescript works properly the first time it is  
> called, the second time ii is called however texshop complains that  
> it can't locate the file example.tex  (in German: "Der Ort des  
> Dokuments 'example.tex' konnte nicht festgestellt werden"), and it  
> wants me to "save as ...". Any ideas what's going wrong here? Thanks,
> Ingo
> ...

Howdy,

Is there some reason you don't just define a new TeXShop engine file?  
Go to ~/Library/TeXShop/Engines/. Duplicate one of the .engine files  
there and rename it latexdb.engine; this saves you from making the  
file executable later. Open the latexdb.engine file in TeXShop and  
replace the contents with

#!/bin/bash
latexdb "$1"

and save it. This ``engine'' is executed in the directory with the  
source file.

To use it just select the latexdb engine in the drop down menu on the  
toolbar at the top of the source file (it that isn't there Ctl-Click  
on the toolbar and choose to configure it). To make it the default  
engine add the line

%!TEX TS-program = latexdb

at, or near, the top of the file. Then Cmd-T will automatically  
execute the latexdb engine for typesetting.

Good Luck,

Herb Schulz
(herbs at wideopenwest.com)


------------------------- Info --------------------------
Mac-TeX Website: http://www.esm.psu.edu/mac-tex/
          & FAQ: http://latex.yauh.de/faq/
TeX FAQ: http://www.tex.ac.uk/faq
List Archive: http://tug.org/pipermail/macostex-archives/




More information about the macostex-archives mailing list