all messages for Emacs-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
From: Sebastian Tennant <sebyte@smolny.plus.com>
To: emacs-devel@gnu.org
Subject: Re: define-minor-mode, auto-mode-alist & change-major-mode-with-file-name
Date: Sun, 05 Feb 2012 17:52:44 +0000	[thread overview]
Message-ID: <39ap182b.fsf@chimera.gnukahvesi.net> (raw)
In-Reply-To: CANbX364Tmr3xCh_1s9ESuzTbhaVHkEiDZ8U3s7kJVdngvWEavg@mail.gmail.com

Quoth Lennart Borgman <lennart.borgman@gmail.com>:
> On Sun, Feb 5, 2012 at 14:57, Sebastian Tennant <sebyte@smolny.plus.com> wrote:
>> (define-minor-mode test-me-mode "Test Me"
>>  :lighter " TM" (message "I have been Tested."))
>>
>> (add-to-list 'auto-mode-alist '("\\.test-me\\'" . test-me-mode))
>
> auto-mode-alist is for major modes, not minor modes.

Ah.

> If you want to turn on a minor mode a way to do it is to use the major
> modes mode hook.

It doesn't say that in elisp.info!  But it does beg the question why am I using
a minor mode?  Thanks.
-- 
Emacs' AlsaPlayer - Music Without Jolts
Lightweight, full-featured and mindful of your idyllic happiness.
http://home.gna.org/eap




      reply	other threads:[~2012-02-05 17:52 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2012-02-05 13:57 define-minor-mode, auto-mode-alist & change-major-mode-with-file-name Sebastian Tennant
2012-02-05 14:33 ` Lennart Borgman
2012-02-05 17:52   ` Sebastian Tennant [this message]

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=39ap182b.fsf@chimera.gnukahvesi.net \
    --to=sebyte@smolny.plus.com \
    --cc=emacs-devel@gnu.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
Code repositories for project(s) associated with this external index

	https://git.savannah.gnu.org/cgit/emacs.git
	https://git.savannah.gnu.org/cgit/emacs/org-mode.git

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.