[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: Minor modes and file names
From: |
Robert Pluim |
Subject: |
Re: Minor modes and file names |
Date: |
Thu, 28 Jan 2021 17:15:46 +0100 |
>>>>> On Thu, 28 Jan 2021 16:57:11 +0100, steve-humphreys@gmx.com said:
steve-humphreys> I have made a minor made for texinfo and noticed that the
minor mode
steve-humphreys> does not take effect unless tho file name matches the
minor mode name.
steve-humphreys> For instance, changing the name of the file to
"crucible-mode-2021-01-28.el"
steve-humphreys> the minor mode fails to load.
steve-humphreys> ----- crucible-mode.el -----
steve-humphreys> (define-minor-mode crucible-mode ...)
steve-humphreys> (provide 'crucible-mode)
steve-humphreys> ----- gtexinfo.el -----
steve-humphreys> (add-to-list
steve-humphreys> 'load-path "~/Genadm/build/gungadin-1.0/elisp/crucible")
steve-humphreys> (require 'crucible-mode)
steve-humphreys> (add-hook 'texinfo-mode-hook 'crucible-mode)
This is expected and documented:
(require FEATURE &optional FILENAME NOERROR)
Probably introduced at or before Emacs version 15.
If feature FEATURE is not loaded, load it from FILENAME.
If FEATURE is not a member of the list `features', then the feature is
not loaded; so load the file FILENAME.
If FILENAME is omitted, the printname of FEATURE is used as the file
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
name, and `load' will try to load this name appended with the suffix
`.elc', `.el'