Zsh Mailing List Archive
Messages sorted by:
Reverse Date,
Date,
Thread,
Author
Re: jobs -d &>/dev/null still produces output?
- X-seq: zsh-users 10930
- From: Peter Stephenson <p.w.stephenson@xxxxxxxxxxxx>
- To: Zsh Users <zsh-users@xxxxxxxxxx>
- Subject: Re: jobs -d &>/dev/null still produces output?
- Date: Sat, 4 Nov 2006 11:51:10 +0000
- In-reply-to: <17393e3e0611031159n61dec831q7ca0ce6ccfb8a421@xxxxxxxxxxxxxx>
- Mailing-list: contact zsh-users-help@xxxxxxxxxx; run by ezmlm
- References: <17393e3e0611031048j2c28e9b4w996c1690926d7b95@xxxxxxxxxxxxxx> <20061103194239.9587ede2.pws@xxxxxxx> <17393e3e0611031159n61dec831q7ca0ce6ccfb8a421@xxxxxxxxxxxxxx>
On Fri, 3 Nov 2006 14:59:07 -0500
"Matt Wozniski" <godlygeek@xxxxxxxxx> wrote:
> On 11/3/06, Peter Stephenson <pws@xxxxxxx> wrote:
> > "Matt Wozniski" <godlygeek@xxxxxxxxx> wrote:
> > > sleep 1000 &
> > > jobs -d &>/dev/null
> > >
> > > Why does this still produce output?
> >
> > The line you're seeing is the same line that would usually be produced
> > when, for example, you run "fg" and the process that's brought to the
> > foreground is running in a different directory. Since this is purely an
> > interactive informational message it's directed straight to the terminal.
>
> On a machine that I can't use the latest cvs on: Is there any sort of
> file descriptor magic that I can use to work around this and get it to
> send that to somewhere other than the terminal, or am I just stuck
> with its current behavior?
I can't think of anything you can do in the shell: it's hard-wired to
the terminal so you would somehow have to persuade the output to come back
from it. There's no use using a pseudoterminal since you can't change
the terminal of the shell that's actually running... unless there's some
fiendishly clever trick using the zsh/clone module of cloning the shell
into a new pseudoterminal. I couldn't get this to work with zsh/zpty since
(I think) clone doesn't get passed the new terminal early enough.
--
Peter Stephenson <p.w.stephenson@xxxxxxxxxxxx>
Web page now at http://homepage.ntlworld.com/p.w.stephenson/
Messages sorted by:
Reverse Date,
Date,
Thread,
Author