mirror of
https://github.com/doomemacs/doomemacs
synced 2025-08-03 12:27:26 -05:00
Fix over-indentation with electric-indent-mode and narf-electric-indent-words
This commit is contained in:
@ -142,7 +142,7 @@ enable multiple minor modes for the same regexp.")
|
|||||||
(defvar-local narf-electric-indent-words '())
|
(defvar-local narf-electric-indent-words '())
|
||||||
(setq electric-indent-chars '(?\n ?\^?))
|
(setq electric-indent-chars '(?\n ?\^?))
|
||||||
(push (lambda (c)
|
(push (lambda (c)
|
||||||
(when (eolp)
|
(when (and (eolp) narf-electric-indent-words)
|
||||||
(save-excursion
|
(save-excursion
|
||||||
(backward-word)
|
(backward-word)
|
||||||
(looking-at-p (concat "\\<" (regexp-opt narf-electric-indent-words))))))
|
(looking-at-p (concat "\\<" (regexp-opt narf-electric-indent-words))))))
|
||||||
|
Reference in New Issue
Block a user