refactor(emacs): Cleanup

This commit is contained in:
Madeleine Sydney
2025-02-17 02:51:21 -07:00
parent 584cff0bd2
commit 0c2e7d7d6d
2 changed files with 55 additions and 51 deletions

View File

@@ -64,10 +64,8 @@
"If any Evil Ex search highlightings are active, remove them and return t. "If any Evil Ex search highlightings are active, remove them and return t.
Otherwise, nil." Otherwise, nil."
(let ((names '(evil-ex-substitute evil-ex-search))) (let ((names '(evil-ex-substitute evil-ex-search)))
(if (-any #'evil-ex-hl-active-p names) (when (-any #'evil-ex-hl-active-p names)
(progn (evil-ex-nohighlight) (prog1 t (evil-ex-nohighlight)))))
t)
nil)))
(add-hook 'syd-escape-hook #'syd-evil-nohl-h) (add-hook 'syd-escape-hook #'syd-evil-nohl-h)
(general-def (general-def

View File

@@ -113,6 +113,11 @@
:maps 'help-mode-map :maps 'help-mode-map
"<escape>" #'syd/escape) "<escape>" #'syd/escape)
;; Insert
(general-def
:prefix-map 'syd-leader-insert-map
"u" #'insert-char)
;; Leader ;; Leader
(general-def (general-def
:keymaps 'syd-leader-map :keymaps 'syd-leader-map
@@ -127,7 +132,8 @@
"f" `("File" . ,syd-leader-file-map) "f" `("File" . ,syd-leader-file-map)
"s" `("Search" . ,syd-leader-search-map) "s" `("Search" . ,syd-leader-search-map)
"h" `("Help" . ,help-map) "h" `("Help" . ,help-map)
"n" `("Notes" . ,syd-leader-notes-map))) "n" `("Notes" . ,syd-leader-notes-map)
"i" `("Insert" . ,syd-leader-insert-map)))
(syd-keybinds-initialise) (syd-keybinds-initialise)