From c983c98abec92e87779b07c793cfd363d293aca8 Mon Sep 17 00:00:00 2001 From: Adam Goldsmith Date: Sat, 5 Aug 2017 12:25:29 -0400 Subject: [PATCH] Add longlines minor mode to highlight long lines --- .emacs.d/init.el | 14 ++++++++++++++ 1 file changed, 14 insertions(+) diff --git a/.emacs.d/init.el b/.emacs.d/init.el index a476e69..c998332 100644 --- a/.emacs.d/init.el +++ b/.emacs.d/init.el @@ -146,6 +146,20 @@ (add-hook 'gud-mode-hook '(lambda () (setq-local comint-prompt-read-only t)))) +(use-package whitespace + :config + (define-minor-mode whitespace-longlines-mode + :lighter " ll" + :init-value nil + :global nil + :group 'whitespace + (let ((whitespace-style '(face lines-tail))) + (whitespace-mode (if whitespace-longlines-mode + 1 -1))) + ;; sync states (running a batch job) + (setq whitespace-longlines-mode whitespace-mode)) + (add-hook 'prog-mode-hook #'whitespace-longlines-mode)) + (use-package org :defer