[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Bug#249597: texmf: Leaves spurious tempfiles around



On Fri, May 21, 2004 at 10:58:10AM +0200, Hilmar Preusse wrote:
> On 21.05.04 Frank K?ster (frank@debian.org) wrote:
> 
> Hi,
> 
> > Two problems:
> > 
> > - if it turns out later that something went wrong, the file is lost. Not
> >   a big issue, since /var/lib/texmf/web2c/*.log is still there.
> > 
> And a "grep ^! /var/lib/texmf/web2c/*.log" should not be that hard.
> 
> > - What should we do with the "Output of ... is in $TEMPFILE" message? We
> >   would have to define a trap and redefine it before the second
> >   call. (or use the same tempfile. That's probably better.)
> > 
> How about:
> 
> if `fmtutil --all >> $TEMPFILE`; then rm $TEMPFILE; else echo -e \
> "\nSomething went wrong. Output of initex is in $TEMPFILE."; fi
> 
> Don't know, how bash-specific that is.

Oh, missed this mail before reply :).

I'm not sure about the bash-specificness of -e, but it isn't needed. I
don't think you need newlines, and even if so, simply use two echo
statement.

But your code layout is a bit suboptimal (you can do linebreaks in if's
like I showed), and it's wrong in that you now try to execute the output
for fmtutil --all. You should drop the backtics, if takes a command to
test for exit status.

Hope this helps,
--Jeroen

-- 
Jeroen van Wolffelaar
Jeroen@wolffelaar.nl (also for Jabber & MSN; ICQ: 33944357)
http://Jeroen.A-Eskwadraat.nl



Reply to: