From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!.POSTED!not-for-mail From: Emanuel Berg Newsgroups: gmane.emacs.help Subject: Re: minor-mode hook not run Date: Tue, 20 Mar 2018 22:17:41 +0100 Organization: Aioe.org NNTP Server Message-ID: <86vadqsayy.fsf@zoho.com> References: <2c3c91da-0f8e-cad2-1746-b3f7a66da98d@easy-emacs.de> NNTP-Posting-Host: blaine.gmane.org Mime-Version: 1.0 Content-Type: text/plain X-Trace: blaine.gmane.org 1521580726 1316 195.159.176.226 (20 Mar 2018 21:18:46 GMT) X-Complaints-To: usenet@blaine.gmane.org NNTP-Posting-Date: Tue, 20 Mar 2018 21:18:46 +0000 (UTC) User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/24.4 (gnu/linux) To: help-gnu-emacs@gnu.org Original-X-From: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Tue Mar 20 22:18:42 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 1eyOeY-0000F0-0X for geh-help-gnu-emacs@m.gmane.org; Tue, 20 Mar 2018 22:18:42 +0100 Original-Received: from localhost ([::1]:51783 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1eyOgZ-0003wA-Fl for geh-help-gnu-emacs@m.gmane.org; Tue, 20 Mar 2018 17:20:47 -0400 X-Received: by 10.223.199.8 with SMTP id k8mr1654720wrg.3.1521580662703; Tue, 20 Mar 2018 14:17:42 -0700 (PDT) X-FeedAbuse: http://nntpfeed.proxad.net/abuse.pl feeded by 78.192.65.63 Original-Path: usenet.stanford.edu!n196no1375024wmd.0!news-out.google.com!a12ni2001wmg.0!nntp.google.com!feeder1-2.proxad.net!proxad.net!feeder1-1.proxad.net!nntpfeed.proxad.net!news.muarf.org!news.gegeweb.eu!gegeweb.org!aioe.org!.POSTED!not-for-mail Original-Newsgroups: gnu.emacs.help Original-Lines: 22 Original-NNTP-Posting-Host: UHWYWQF2IuZrSKObhXEbig.user.gioia.aioe.org Original-X-Complaints-To: abuse@aioe.org Cancel-Lock: sha1:PE8XQB1TtyiQsayIIl5BdF32mX4= Mail-Copies-To: never X-Notice: Filtered by postfilter v. 0.8.3 Original-Xref: usenet.stanford.edu gnu.emacs.help:222101 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:116219 Archived-At: Stefan Monnier wrote: > Adding elements to one's own hook here > definitely deserve a "bug ugly hack" comment > explaining why you'd want to do it that way. > > In any case, the minor mode `foo` will run > `foo-hook` but not `foo-mode-hook` (which > would be run by the `foo-mode` minor mode). Callings things foo isn't encouraged BTW. It finds its way into "production code" soon enough. If it is just a joke intended for personal computer exploration, instead make something up: make it replace the char at point by the next char in the English alphabet, and call it "abc-mode", or whatever, just not foo, bar, foobar, main, or anything like that. -- underground experts united http://user.it.uu.se/~embe8573