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

Re: have '&' automatically disown?



Thanks for your response and clarification Peter,

>>>>> On February 5, 2010 Peter Stephenson <pws@xxxxxxx> wrote:

> When you "setopt monitor" again *then* jobs you didn't explicitly disown
> are reported.

Really?  That's not what I see, patchlevel 1.4847.

It is the case that while monitor is off, 'jobs' does still list the
jobs, however 'fg' reports "fg: no job control in this shell.".  I
turned monitor back on and 'fg'd a job, but now neither C-z nor C-c
will interrupt that job:

[~] greg@lwm| zsh -f
lwm% setopt nomonitor nohup nocheckjobs
lwm% 
lwm% sleep 2000 &
lwm% sleep 3000 &
lwm% jobs
[1]  - running    sleep 2000
[2]  + running    sleep 3000
lwm% fg %1
fg: no job control in this shell.
lwm% setopt monitor
lwm% jobs
[1]  - running    sleep 2000
[2]  + running    sleep 3000
lwm% fg %1
[1]  - running    sleep 2000
^C^C^C^Z^Z^Z^Z


Greg



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