Zsh Mailing List Archive
Messages sorted by:
Reverse Date,
Date,
Thread,
Author
Re: "{ } always { }" construct and return in called functions
On May 19, 8:22am, Mikael Magnusson wrote:
} Subject: Re: "{ } always { }" construct and return in called functions
}
} On Tue, May 19, 2015 at 7:04 AM, Bart Schaefer
} > If you have some other job running in the background, the shell does
} > not exit when 'exit' is called from a zle widget:
}
} A good theory, but
} zshrun ~> echo $options[checkjobs]
} off
} I've always had that option turned off.
}
} Also, since the command is run with &| then surely there are no jobs
} either way?
I was presuming that whatever other job was preventing the exit had been
started somewhere earlier in the startup sequence, and was not the same
job started by _accept_and_quit.
} It seems to be run once in the background by the widget, and then
} another one in the foreground that I can ctrl-c out of. I only press
} enter the one time.
This makes me suspect that both _accept_and_quit and also accept-line
are being executed.
Perhaps the shell is receiving "\r\n" and executing _accept_and_quit on
the \r followed by accept-line on the \n ?
Try
zsh -c "${BUFFER}" &|
BUFFER=""
exit
??
Messages sorted by:
Reverse Date,
Date,
Thread,
Author