[OS X TeX] aux files

Claus Gerhardt gerhardt at math.uni-heidelberg.de
Sun Feb 20 10:50:32 EST 2005


Sorry, there was a typo in the script.

Below is an Applescript that should remove the log file of any tex file  
that is front most in TeXShop. You can save it as a TeXShop Macro.

Claus


tell application "TeXShop"
	get path of document of window 1
	set fileName to result
end tell
set {baseName, texName, pdfName, namePath, dirName, dirNameunquoted,  
logName, logPath, rtfName} to setnamets(fileName)
set logPath to quoted form of logPath
do shell script "rm "& logPath

on setnamets(x)
	set n to (number of characters of contents of x)
	set fileNamequoted to quoted form of x
	set windowName to do shell script "basename " & fileNamequoted
	set m to (number of characters of contents of windowName)
	set dirName to quoted form of (characters 1 thru (n - m - 1) of x as  
string)
	set dirNameunquoted to (characters 1 thru (n - m - 1) of x as string)
	set theText to contents of windowName as string
	
	set n to (number of characters of contents of theText)
	set i to n as number
	
	repeat while i > 0
		if character i of theText is equal to "." then
			set m to i
			exit repeat
		else
			set i to (i - 1)
		end if
	end repeat
	
	set baseName to (characters 1 thru (m - 1) of theText as string)
	set texName to baseName & ".tex"
	set namePath to dirNameunquoted & "/" & baseName as string
	set pdfName to namePath & ".pdf" as string
	set rtfName to namePath & ".rtf" as string
	set logPath to namePath & ".log" as string
	set logName to baseName & ".log" as string
	
	try
		tell application "TeXShop"
			save document texName
		end tell
	end try
	return {baseName, texName, pdfName, namePath, dirName,  
dirNameunquoted, logName, logPath, rtfName} as list
end setnamets

On Feb 20, 2005, at 16:30, nachman wrote:

> Folks,
>
> This is probably an OS X question.  On occasion, using XeLateX to make  
> text for slides for Keynote, TeXShop has a problem and runs off the  
> deep end, generating a masssive log file.  OK, I can live with this.   
> But after forcing TeXShop to quit I sometimes have a log file that  
> fills up half my hard disk.  Trashing the file is possible, but  
> emptying the trash is not.  Even after quitting TeXShop I get a "in  
> use"  error message.  How do I get rid of those files without a  
> complete reboot?
>
> Jack Nachman
> *******************************************************************
> Louis J. (Jack) Nachman           p  248 370 3430
> Professor and Chair
> Department of Mathematics and Statistics
>                                                         f  248 370 4184
> Oakland University
> Rochester, MI  48309		e nachman at oakland.edu
> *******************************************************************
> --------------------- 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 Post: <mailto:MacOSX-TeX at email.esm.psu.edu>
>
>




Claus Gerhardt
Institut für Angewandte Mathematik
Ruprecht-Karls-Universität Heidelberg
Im Neuenheimer Feld 294
69120 Heidelberg
Germany

http://www.math.uni-heidelberg.de/studinfo/gerhardt/

PGP Public Key available from
ldap://keyserver.pgp.com
http://pgpkeys.mit.edu

Digital Signature for pdf files available from
http://www.math.uni-heidelberg.de/studinfo/gerhardt/ 
DataExchangeClausGerhardt.fdf

--------------------- 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 Post: <mailto:MacOSX-TeX at email.esm.psu.edu>





More information about the MacOSX-TeX mailing list