diff --git a/emacs/.emacs.d/init.el b/emacs/.emacs.d/init.el index f677319..2c128ad 100644 --- a/emacs/.emacs.d/init.el +++ b/emacs/.emacs.d/init.el @@ -25,6 +25,11 @@ ;;; Code: +(defun init-whitespace-only-tabs-mode () + "Enable whitespace mode with only tabs showing." + (setq-local whitespace-style '(face tabs)) + (whitespace-mode)) + (eval-and-compile (let ((load-directory (file-name-directory @@ -324,9 +329,9 @@ (add-hook 'python-mode-hook 'flycheck-mode) -(add-hook 'web-mode-hook 'oni-whitespace-only-tabs-mode) +(add-hook 'web-mode-hook 'init-whitespace-only-tabs-mode) -(add-hook 'makefile-mode-hook 'oni-whitespace-only-tabs-mode) +(add-hook 'makefile-mode-hook 'init-whitespace-only-tabs-mode) (add-hook 'makefile-mode-hook 'electric-pair-local-mode)