Zsh Mailing List Archive
Messages sorted by:
Reverse Date,
Date,
Thread,
Author
Re: Getting the name of zsh-generated temp file?
- X-seq: zsh-users 6077
- From: Lloyd Zusman <ljz@xxxxxxxxxx>
- To: zsh-users@xxxxxxxxxx
- Subject: Re: Getting the name of zsh-generated temp file?
- Date: Mon, 05 May 2003 14:27:02 -0400
- >return-path: ljz@xxxxxxxxxx
- In-reply-to: <1030505165710.ZM24097@xxxxxxxxxxxxxxxxxxxxxxx> (Bart Schaefer's message of "Mon, 5 May 2003 16:57:10 +0000")
- Mailing-list: contact zsh-users-help@xxxxxxxxxx; run by ezmlm
- References: <d6ixslhl.fsf@xxxxxxxxxx> <20030505133637.GA26425@xxxxxxxx> <1030505165710.ZM24097@xxxxxxxxxxxxxxxxxxxxxxx>
- Reply-to: ljz@xxxxxxxxxx
- Sender: Lloyd Zusman <ljz@xxxxxxxxxx>
"Bart Schaefer" <schaefer@xxxxxxxxxxxxxxxx> writes:
> It should be pointed out that assigning the =(...) expression to a variable
> is meant to be the only way to get the temporary file to persist. In all
> other cases (and, in older versions of zsh, even for assignments) the file
> is automatically removed as soon as the surrounding expression completes.
>
> Lloyd originally wrote:
>> One of these is left sitting around in /tmp after each termination
>
> In short, This Should Not Happen unless zsh is crashing or you are doing
> something unusual to cause the file to be left behind.
I am using 'exec' to invoke a different executable from within my zsh
script. I think that this is preventing the temp file from being
removed. I have control of the other executable, and so I now can pass
the name of the temp file as an argument to this executable, who now
explicitly removes it.
And I should add I deliberately want to replace my script with the other
executable, which is why I'm using 'exec'.
--
Lloyd Zusman
ljz@xxxxxxxxxx
Messages sorted by:
Reverse Date,
Date,
Thread,
Author