mirror of
https://codeberg.org/scip/dot-emacs.git
synced 2025-12-17 12:30:59 +01:00
fix electric indent, tab indent and smartparens
This commit is contained in:
@@ -122,7 +122,7 @@ Returns t if version changed, nil otherwise."
|
||||
;; enable outshine mode
|
||||
(outshine-hook-function)
|
||||
|
||||
(electric-indent-mode t)))
|
||||
(electric-indent-local-mode t)))
|
||||
|
||||
;; use UP arrow for history in *ielm* as well, just as C-up
|
||||
(add-hook 'comint-mode-hook
|
||||
|
||||
@@ -42,11 +42,13 @@ Used when enabling smartparens-mode."
|
||||
|
||||
;; automatically enable where needed
|
||||
(add-something-to-mode-hooks
|
||||
'(rust emacs-lisp ielm lisp lisp-interaction scheme slime-repl ) 'smartparens-mode)
|
||||
'(rust emacs-lisp ielm lisp elisp lisp-interaction scheme slime-repl ) 'smartparens-mode)
|
||||
|
||||
;; also in some select prog modes
|
||||
(add-something-to-mode-hooks
|
||||
'(perl ruby c c++ sh makefile config-general yaml go) 'smartparens-mode)
|
||||
;; (add-something-to-mode-hooks
|
||||
;; '(perl ruby c c++ sh makefile config-general yaml go) (smartparens-mode t))
|
||||
;; the above doesn't work anymore, for whatever reasons, so I enable it for all
|
||||
(smartparens-global-mode t)
|
||||
|
||||
;; via https://ebzzry.io/en/emacs-pairs/:
|
||||
(defmacro def-pairs (pairs)
|
||||
|
||||
@@ -277,3 +277,6 @@ in between will be killed. If INS is non-nil, it will be inserted then."
|
||||
|
||||
(advice-add 'iedit-mode :after '(lambda (&rest args) ;; restore previously saved
|
||||
(setq buffer-undo-list tvd-buffer-undo-list))))
|
||||
|
||||
(add-hook 'text-mode-hook
|
||||
(lambda () (electric-indent-local-mode -1)))
|
||||
|
||||
Reference in New Issue
Block a user