fix(direnv): fix void function error in emacs30
This commit is contained in:
parent
ede616fdd7
commit
0a635e9df9
1 changed files with 3 additions and 1 deletions
|
@ -15,7 +15,9 @@
|
|||
;; hooks, but not the body.
|
||||
(add-hook! 'envrc-global-mode-hook
|
||||
(defun +direnv-init-global-mode-earlier-h ()
|
||||
(let ((fn #'envrc-global-mode-enable-in-buffers))
|
||||
(let ((fn (if (fboundp #'envrc-global-mode-enable-in-buffers)
|
||||
#'envrc-global-mode-enable-in-buffers ; Removed in Emacs 30.
|
||||
#'envrc-global-mode-enable-in-buffer)))
|
||||
(if (not envrc-global-mode)
|
||||
(remove-hook 'change-major-mode-after-body-hook fn)
|
||||
(remove-hook 'after-change-major-mode-hook fn)
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue