diff --git a/core/siren-core-modules.el b/core/siren-core-modules.el index 74f11f5..52282ed 100644 --- a/core/siren-core-modules.el +++ b/core/siren-core-modules.el @@ -62,6 +62,7 @@ (require 'siren-helm-ag) (require 'siren-helm-open-github) (require 'siren-helm-swoop) +(require 'siren-imenu) (require 'siren-recursive-narrow) (require 'siren-scroll-half-screen) diff --git a/modules/navigation/siren-helm.el b/modules/navigation/siren-helm.el index c465991..9eac297 100644 --- a/modules/navigation/siren-helm.el +++ b/modules/navigation/siren-helm.el @@ -6,16 +6,20 @@ ;;; Code: -(require 'imenu) +(use-package helm-config + :straight (helm) + :demand t + :bind + ("C-c h" . helm-command-prefix) + (:map helm-command-map + ("M" . helm-man-woman)) -(use-package imenu-anywhere - :config - (set-default 'imenu-auto-rescan t) - (set-default 'imenu-max-item-length 160) - (set-default 'imenu-max-items 400)) + :custom + (helm-command-prefix-key nil)) (use-package helm - :demand t + :after (helm-config) + :defer t :hook (helm-minibuffer-set-up . siren-helm--hide-minibuffer-maybe) (helm-after-initialize . siren-helm--toggle-source-header-line) @@ -24,30 +28,14 @@ (helm-cleanup . siren-helm--show-neotree-maybe) (helm-cleanup . siren-helm--show-treemacs-maybe) - :bind - ("C-t" . helm-imenu) - ("C-c t" . helm-imenu-anywhere) - ("C-x C-f" . helm-find-files) - ("C-c f f" . helm-for-files) - ("C-c f r" . helm-recentf) - ("C-c C-m" . helm-M-x) - (:map helm-command-map - ("M" . helm-man-woman)) - :custom - (helm-M-x-always-save-history t) - (helm-M-x-fuzzy-match t) (helm-always-two-windows t) (helm-autoresize-max-height 48) (helm-autoresize-min-height 10) (helm-autoresize-mode nil) - (helm-buffer-max-length 64) (helm-case-fold-search 'smart) - (helm-command-prefix-key "C-c h") (helm-display-header-line t) (helm-echo-input-in-header-line t) - (helm-ff-file-name-history-use-recentf t) - (helm-ff-search-library-in-sexp t) (helm-file-name-case-fold-search 'smart) (helm-split-window-default-side 'below) (siren-helm--did-hide-neotree nil) @@ -81,7 +69,8 @@ "Turn `popwin-mode' on for *Help* buffers." (when (boundp 'popwin:special-display-config) (customize-set-variable 'popwin:special-display-config - (add-to-list 'popwin:special-display-config 'help-mode nil #'eq)))) + (add-to-list 'popwin:special-display-config + 'help-mode nil #'eq)))) (defun siren-helm--hide-neotree (&rest plist) (when (and (fboundp 'neotree-hide) @@ -115,15 +104,43 @@ (select-window win)))) :config - (require 'helm-config) - - (require 'helm-command) - (require 'helm-files) - (require 'helm-imenu) - (advice-add 'helm :before 'siren-helm--hide-neotree) (advice-add 'helm :before 'siren-helm--hide-treemacs)) +(use-package helm-command + :straight (helm) + :after (helm-config) + :bind + ("C-c C-m" . helm-M-x) + + :custom + (helm-M-x-always-save-history t) + (helm-M-x-fuzzy-match t)) + +(use-package helm-files + :straight (helm) + :after (helm-config) + :bind + ("C-x C-f" . helm-find-files) + + :custom + (helm-buffer-max-length 64) + (helm-ff-file-name-history-use-recentf t) + (helm-ff-search-library-in-sexp t)) + +(use-package helm-for-files + :straight (helm) + :after (helm-config) + :bind + ("C-c f f" . helm-for-files) + ("C-c f r" . helm-recentf)) + +(use-package helm-imenu + :straight (helm) + :after (helm-config) + :bind + ("C-t" . helm-imenu)) + (use-package helm-descbinds :defer t) diff --git a/modules/navigation/siren-imenu.el b/modules/navigation/siren-imenu.el new file mode 100644 index 0000000..9d105c6 --- /dev/null +++ b/modules/navigation/siren-imenu.el @@ -0,0 +1,22 @@ +;;; siren-imenu.el --- jimeh's Emacs Siren: imenu configuration. + +;;; Commentary: + +;; Basic configuration for imenu. + +;;; Code: + +(require 'imenu) +(require 'siren-helm) + +(use-package imenu-anywhere + :bind + ("C-c t" . helm-imenu-anywhere) + + :config + (set-default 'imenu-auto-rescan t) + (set-default 'imenu-max-item-length 160) + (set-default 'imenu-max-items 400)) + +(provide 'siren-imenu) +;;; siren-imenu.el ends here diff --git a/modules/tools/siren-helm-make.el b/modules/tools/siren-helm-make.el old mode 100644 new mode 100755 index 606b30f..e936bf4 --- a/modules/tools/siren-helm-make.el +++ b/modules/tools/siren-helm-make.el @@ -9,6 +9,7 @@ (require 'siren-helm) (use-package helm-make + :after (helm-config) :bind (:map helm-command-map ("m" . helm-make-projectile))