Skip to content

Commit a32eb79

Browse files
committed
tweak(core): better hook documentation in +make-first-file-hook!
1 parent 06f7123 commit a32eb79

File tree

1 file changed

+5
-2
lines changed

1 file changed

+5
-2
lines changed

core/me-lib.el

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -329,9 +329,12 @@ EXT-REGEXP. When it runs, this function provides a feature named
329329
(fn-name (intern (format "+first-%s-file:after-a" (if filetype (format "-%s" filetype) ""))))
330330
(hook-name (intern (format "minemacs-first%s-file-hook" (if filetype (format "-%s" filetype) ""))))
331331
(feature-name (intern (format "minemacs-first%s-file" (if filetype (format "-%s" filetype) ""))))
332-
(hook-docs (format "This hook will be run after opening the first %s file (files that matches \"%s\").
332+
(hook-docs (format "This hook will be run before opening the first %s file.
333+
334+
Applies to files that matches %S.
335+
333336
Executed before `find-file-noselect', it runs all hooks in `%s' and provide the `%s' feature."
334-
filetype ext-regexp hook-name feature-name)))
337+
(or filetype "") (eval ext-regexp) hook-name feature-name)))
335338
`(progn
336339
(+log! "Setting up hook `%s' -- function `%s' -- feature `%s'." ',hook-name ',fn-name ',feature-name)
337340
(defcustom ,hook-name nil ,hook-docs :group 'minemacs-core :type 'hook)

0 commit comments

Comments
 (0)