Emacs/ESS: active process exist kill them and exit anyway?
I finally found a way to prevent this annoying question popping up each time I want to quit Emacs. It has been annoying me for ages, and all the solutions on the web did not work. So here is the code to add to .emacs
:
(add-hook 'ess-post-run-hook (lambda () (set-process-query-on-exit-flag (get-ess-process ess-current-process-name) nil)) nil)
It was quite simple, indeed the solution was just to find the good hook, that was executed early enough (it looks like kill-emacs-hook
is run after the question was already asked) but not too early (some tips here and there mentioning inferior-ess-mode-hook
failed because the process doesn't exist yet when the hook is run). I was focusing on getting the process with (get-buffer-process (current-buffer))
and a lot of that kind of things, but it was apparently of little importance: everything just works when you do it on the right time.
Xavier Robin
Published Tuesday, May 25, 2010 18:49 CEST
Permalink: /blog/2010/05/25/emacs-ess-active-process-exist-kill-them-and-exit-anyway
Tags:
Computers
Comments: 1
Comments
By Julian on Friday, December 10, 2010 00:04 CET
Thanks for this! It works like a charm, and that annoying pop up window is gone.