Emacs clean up.
This commit is contained in:
+9
-14
@@ -3,7 +3,10 @@
|
||||
;; C-h works too, except in normal/motion state where it moves to the window on the left.
|
||||
|
||||
;;; Code:
|
||||
;;;; 1. Emac setup, files, packages and paths
|
||||
;;;; 1. Emac setup, gc, files, packages
|
||||
(add-hook 'emacs-startup-hook
|
||||
(lambda () (setq gc-cons-threshold (* 16 1024 1024))))
|
||||
|
||||
(dolist (bin (list (expand-file-name "~/.local/bin")
|
||||
(expand-file-name "~/.go/bin")))
|
||||
(add-to-list 'exec-path bin)
|
||||
@@ -134,7 +137,7 @@
|
||||
(kbd "TAB") #'my/insert-tab
|
||||
(kbd "C-SPC") #'completion-at-point)
|
||||
|
||||
;; C-p, C-f and C-b are assigned to Consult below.
|
||||
;; C-p and C-f are assigned to Consult below, C-m to ibuffer.
|
||||
(evil-define-key '(normal motion) 'global
|
||||
(kbd "C-e") #'dired-jump))
|
||||
|
||||
@@ -144,7 +147,7 @@
|
||||
;; Don't add its global [b ]b [e ]e ... bindings.
|
||||
(evil-collection-want-unimpaired-p nil)
|
||||
:config
|
||||
(evil-collection-init '(info)))
|
||||
(evil-collection-init '(info ibuffer)))
|
||||
|
||||
;; Minibuffer. Vertico
|
||||
(with-eval-after-load 'vertico
|
||||
@@ -183,22 +186,16 @@
|
||||
;; Searches start at the project root when there is one, else the current directory.
|
||||
(use-package consult
|
||||
:config
|
||||
;; Hide noise from the buffer picker.
|
||||
(dolist (re '("\\`\\*scratch\\*\\'"
|
||||
"\\`\\*Messages\\*\\'"
|
||||
"\\`\\*Warnings\\*\\'"
|
||||
"\\`\\*xref\\*\\'"))
|
||||
(add-to-list 'consult-buffer-filter re))
|
||||
|
||||
;; Don't re-run the preview on every keystroke while typing a search.
|
||||
(consult-customize consult-ripgrep
|
||||
:preview-key '(:debounce 0.4 any)))
|
||||
|
||||
;; Bind immediately, without waiting for consult to load.
|
||||
;; C-m opens the full ibuffer list (evil-collection provides its navigation).
|
||||
(evil-define-key '(normal motion) 'global
|
||||
(kbd "C-p") #'consult-fd
|
||||
(kbd "C-f") #'consult-ripgrep
|
||||
(kbd "C-m") #'consult-buffer)
|
||||
(kbd "C-m") #'ibuffer)
|
||||
|
||||
;;;; 7. Dired
|
||||
(setq dired-dwim-target t
|
||||
@@ -222,12 +219,10 @@
|
||||
;;;; Core config ends here.
|
||||
;;;; -----------------------------------------------------------------
|
||||
;;;; 8. Modules - additional functionality outside of the core init.el
|
||||
|
||||
;; Setup for orgmode
|
||||
(load (locate-user-emacs-file "modules/org.el") nil 'nomessage)
|
||||
|
||||
;; Setup for rss feed
|
||||
(load (locate-user-emacs-file "modules/rss.el") nil 'nomessage)
|
||||
|
||||
;; Magit and the :git command live in modules/git.el.
|
||||
(load (locate-user-emacs-file "modules/git.el") nil 'nomessage)
|
||||
|
||||
|
||||
Reference in New Issue
Block a user