|
From: | Reuben Thomas |
Subject: | bug#18133: Suppressing asynchronous command output |
Date: | Sat, 24 Dec 2016 11:11:37 +0000 |
> Here is the implementation I currently use (from Juri Linkov, message #8,
> second block of code):
>
> (advice-add 'comint-output-filter :after
> "Stop Async Shell Command output from appearing until there is
> output."
> (lambda (process string)
> (when (and (string-match-p "\\*Async Shell Command\\*"
> (buffer-name (process-buffer
> process))))
> (display-buffer (process-buffer process)))))
>
> I think this does what you say: whenever some output arrives, the buffer
> pops up. It does not involve changing the behaviour of display-buffer.
>
> All my patch does is move the advice into a function suitable for
> comint-output-filter-functions. To turn this into a minor mode I would do two things:
If you now try to customize ‘display-buffer-alist’, you'll be told that
this option has been "CHANGED outside Customize". You can avoid that by
doing
(customize-save-variable
'display-buffer-alist
(add-to-list
'display-buffer-alist '("\\*Async Shell Command\\*"
display-buffer-no-window)))
instead.
[Prev in Thread] | Current Thread | [Next in Thread] |