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

Re: Disowning a stopped job



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?

}     Adding a flag to tell bin_fg() that it's a
}     `%1 &!' and then calling killjb() there isn't hard to implement
}     either, of course, but we got no comments on this, so...

Oops, sorry, I meant to comment on it:

On May 30,  3:42pm, Sven Wischnowsky wrote:
} Subject: Re: Disowning a stopped job
}
} Bart Schaefer wrote:
} 
} > Here's the thing to consider:  `disown %1' is equivalent to `%1 &!'.
} 
} > Would it be weird (or even possible) to have those two variants work in
} > different ways in this case?
} 
} I would actually prefer it if they would differ.  The only possible way
} to implement this is adding a global variable that gets set in execcmd()
} and tested in bin_fg().

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().

-- 
Bart Schaefer                                 Brass Lantern Enterprises
http://www.well.com/user/barts              http://www.brasslantern.com

Zsh: http://www.zsh.org | PHPerl Project: http://phperl.sourceforge.net   



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