From 2ef38b73a719c27b975645a4bbadeb462b265611 Mon Sep 17 00:00:00 2001 From: Henrik Lissner Date: Fri, 8 Dec 2017 22:57:36 -0500 Subject: [PATCH] Remove doom*delete-trailing-whitespace advice (unneeded) --- core/core-editor.el | 11 ----------- 1 file changed, 11 deletions(-) diff --git a/core/core-editor.el b/core/core-editor.el index 0bbaa4b21..4b178e97c 100644 --- a/core/core-editor.el +++ b/core/core-editor.el @@ -112,17 +112,6 @@ with functions that require it (like modeline segments)." buffer)) (advice-add #'make-indirect-buffer :around #'doom*set-indirect-buffer-filename) -(defun doom*delete-trailing-whitespace (orig-fn &rest args) - "Don't affect trailing whitespace on current line." - (let ((linestr (buffer-substring-no-properties - (line-beginning-position) - (line-end-position)))) - (apply orig-fn args) - (when (and (if (featurep 'evil) (evil-insert-state-p) t) - (string-match-p "^[\s\t]*$" linestr)) - (insert linestr)))) -(advice-add #'delete-trailing-whitespace :around #'doom*delete-trailing-whitespace) - (push '("/LICENSE$" . text-mode) auto-mode-alist)