Browse Source

Remove global and add text-mode

master
10sr 5 years ago
parent
commit
467bc0ce99
Signed by: 10sr GPG Key ID: C384BB17CBB19347
1 changed files with 2 additions and 1 deletions
  1. +2
    -1
      emacs.el

+ 2
- 1
emacs.el View File

@@ -353,7 +353,6 @@ found, otherwise returns nil."

;; Basically it should not set globally (instead use something like file local
;; variables or editorconfig), but for most cases I just need this...
(setq-default require-final-newline t)
(defun my-set-require-final-newline ()
"Set `require-final-newline'."
(set (make-local-variable 'require-final-newline)
@@ -361,6 +360,8 @@ found, otherwise returns nil."

(add-hook 'prog-mode-hook
'my-set-require-final-newline)
(add-hook 'text-mode-hook
'my-set-require-final-newline)
(add-hook 'conf-mode-hook
'my-set-require-final-newline)



Loading…
Cancel
Save