Fix conditional loading of helm

It only makes sense to load helm when it's installed, isn't it?
This commit is contained in:
Daniel - 2024-03-05 21:20:56 +01:00
parent b6ecb4eb53
commit 0e9ae4aa4d
Signed by: dbo
GPG Key ID: 784AA8DF0CCDF625
1 changed files with 3 additions and 4 deletions

View File

@ -2960,10 +2960,6 @@ eventuelly be set to nil, however)."
(with-demoted-errors "Cannot activate `vlf': %s"
(require 'vlf-setup))
;; Explicitly require helm, because autoloading is difficult with helm's
;; separate `helm-command-prefix-key' mechanism.
(require 'helm)
;; Global Hooks
(add-hook 'minibuffer-setup-hook 'cursor-intangible-mode)
@ -3060,6 +3056,9 @@ eventuelly be set to nil, however)."
(bind-key "C-S-s" #'counsel-grep-or-swiper))
(when (package-installed-p 'helm)
;; Explicitly require helm, because autoloading is difficult with helm's
;; separate `helm-command-prefix-key' mechanism.
(require 'helm)
(bind-key "M-y" #'helm-show-kill-ring)
(bind-key helm-command-prefix-key #'helm-command-prefix))