From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!.POSTED!not-for-mail From: Stefan Monnier Newsgroups: gmane.emacs.help Subject: Re: Show *compilation* only if build did not succeed Date: Sat, 22 Dec 2018 13:21:31 -0500 Message-ID: References: <87h8f5fvdo.fsf@aminb.org> <87ftupxxdl.fsf@aminb.org> NNTP-Posting-Host: blaine.gmane.org Mime-Version: 1.0 Content-Type: text/plain X-Trace: blaine.gmane.org 1545502809 19803 195.159.176.226 (22 Dec 2018 18:20:09 GMT) X-Complaints-To: usenet@blaine.gmane.org NNTP-Posting-Date: Sat, 22 Dec 2018 18:20:09 +0000 (UTC) User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/27.0.50 (gnu/linux) Cc: help-gnu-emacs@gnu.org To: Amin Bandali Original-X-From: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Sat Dec 22 19:20:05 2018 Return-path: Envelope-to: geh-help-gnu-emacs@m.gmane.org Original-Received: from lists.gnu.org ([208.118.235.17]) by blaine.gmane.org with esmtp (Exim 4.84_2) (envelope-from ) id 1galsa-00052y-OC for geh-help-gnu-emacs@m.gmane.org; Sat, 22 Dec 2018 19:20:04 +0100 Original-Received: from localhost ([::1]:48291 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1galuh-0005qB-D3 for geh-help-gnu-emacs@m.gmane.org; Sat, 22 Dec 2018 13:22:15 -0500 Original-Received: from eggs.gnu.org ([2001:4830:134:3::10]:54326) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1galu8-0005q4-Jd for help-gnu-emacs@gnu.org; Sat, 22 Dec 2018 13:21:41 -0500 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1galu3-0005mC-6i for help-gnu-emacs@gnu.org; Sat, 22 Dec 2018 13:21:40 -0500 Original-Received: from chene.dit.umontreal.ca ([132.204.246.20]:60767) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1galu1-0005kL-LV; Sat, 22 Dec 2018 13:21:34 -0500 Original-Received: from pastel.home (lechon.iro.umontreal.ca [132.204.27.242]) by chene.dit.umontreal.ca (8.14.7/8.14.1) with ESMTP id wBMILW22025876; Sat, 22 Dec 2018 13:21:32 -0500 Original-Received: by pastel.home (Postfix, from userid 20848) id EE84D6AAB6; Sat, 22 Dec 2018 13:21:31 -0500 (EST) In-Reply-To: <87ftupxxdl.fsf@aminb.org> (Amin Bandali's message of "Sat, 22 Dec 2018 12:52:06 -0500") X-NAI-Spam-Flag: NO X-NAI-Spam-Threshold: 5 X-NAI-Spam-Score: 0 X-NAI-Spam-Rules: 2 Rules triggered EDT_SA_DN_PASS=0, RV6444=0 X-NAI-Spam-Version: 2.3.0.9418 : core <6444> : inlines <6989> : streams <1807887> : uri <2768461> X-detected-operating-system: by eggs.gnu.org: Genre and OS details not recognized. X-Received-From: 132.204.246.20 X-BeenThere: help-gnu-emacs@gnu.org X-Mailman-Version: 2.1.21 Precedence: list List-Id: Users list for the GNU Emacs text editor List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Original-Sender: "help-gnu-emacs" Xref: news.gmane.org gmane.emacs.help:119022 Archived-At: > (defadvice compilation-start > (around inhibit-display > (command &optional mode name-function highlight-regexp)) > (if (not (string-match "^\\(find\\|grep\\)" command)) > (cl-letf (((symbol-function 'display-buffer) #'ignore) > ((symbol-function 'set-window-point) #'ignore) > ((symbol-function 'goto-char) #'ignore)) > (save-window-excursion ad-do-it)) > ad-do-it)) BTW, is the `goto-char` override really effective? It doesn't affect calls to goto-char made from byte-compiled code, so there's a good chance that it ends up not doing anything. Stefan