Zsh Mailing List Archive
Messages sorted by: Reverse Date, Date, Thread, Author

Re: Disowning a stopped job



Bart Schaefer wrote:

> On May 31,  2:35pm, Sven Wischnowsky wrote:
> } Subject: PATCH: Re: tag-order problem?
> }
> } [1] My only suggestion at this time would be to think about changing the
> }     warnings to `warning: job is still suspended' (i.e. inserting that
> }     `still' to make it clearer that the job has been disowned but is
> }     still sleeping).  Dunno.
> 
> Or what about something actually useful, like:
> 
>   disown: disowned a stopped job (use `kill -CONT -<pgrp here>')
> 
> where <pgrp here> is of course the actual pgrp of the stopped job.  Is
> there a reason that won't work?

The only case I can think of where it wouldn't work is if the job in
question is a super job.  The user would then have to continue the
sub-job, sometimes (see killjb() in signals.c).

> ...
> 
> As you point out:
> 
> } execcmd() actually inserts a `disown' into the list of command words
> 
> So don't insert a `disown'.  Insert `bg' and delete the job table entry
> in execcmd() the way it's done in execpline2().

Hm, yes, I hadn't thought about that.


Bye
  Sven


-- 
Sven Wischnowsky                         wischnow@xxxxxxxxxxxxxxxxxxxxxxx



Messages sorted by: Reverse Date, Date, Thread, Author