[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: mktemp: not found
From: |
Bruce Korb |
Subject: |
Re: mktemp: not found |
Date: |
Sun, 04 Dec 2011 14:50:28 -0800 |
User-agent: |
Mozilla/5.0 (X11; U; Linux x86_64; en-US; rv:1.9.2.18) Gecko/20110616 SUSE/3.1.11 Thunderbird/3.1.11 |
On 12/04/11 11:57, Jim Meyering wrote:
d=`unset TMPDIR; { mktemp -d -t -p "$destdir_" "$template_"; } 2>/dev/null` \
That should do the same without the cost of a sub-shell.
Or:
d=`
exec 2>/dev/null
unset TMPDIR
mktemp -d -t -p "$destdir_" "$template_"
`
as we discovered recently, there are some commands (builtin's, okay)
where the output goes to stderr before it gets redirected.
So get your fingers in the habit of not using overly long lines
and redirecting junk before the command in question. :)