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 6076
- From: "Bart Schaefer" <schaefer@xxxxxxxxxxxxxxxx>
- To: zsh-users@xxxxxxxxxx
- Subject: Re: Getting the name of zsh-generated temp file?
- Date: Mon, 5 May 2003 16:57:10 +0000
- In-reply-to: <20030505133637.GA26425@xxxxxxxx>
- Mailing-list: contact zsh-users-help@xxxxxxxxxx; run by ezmlm
- References: <d6ixslhl.fsf@xxxxxxxxxx> <20030505133637.GA26425@xxxxxxxx>
On May 5, 2:36pm, Zefram wrote:
} Subject: Re: Getting the name of zsh-generated temp file?
}
} Lloyd Zusman wrote:
} >Within a zsh script, is there any way that I can get the name of the
} >temporary file generated by the =(...) construct?
}
} $ foo==(echo bar)
} $ echo $foo
} /tmp/zshp8oWrV
} $ cat $foo
} bar
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.
Messages sorted by:
Reverse Date,
Date,
Thread,
Author