Move diff-hl configuration to emacs-config

This commit is contained in:
Tom Willemse 2019-02-19 00:53:33 -08:00
parent 45ab0967ab
commit fa7536a85d

View file

@ -49,7 +49,6 @@
(require 'counsel)
(require 'destroy-trailing-whitespace)
(require 'diff-hl)
(require 'diminish)
(require 'ivy)
(require 'ivy-hydra)
@ -163,20 +162,8 @@
(add-hook 'electric-indent-local-mode-hook #'oni:switch-newline-keys)
(global-diff-hl-mode)
(blink-cursor-mode -1)
(defun oni:with-diff-hl-p4-args (orig-fun &rest args)
"Add Perforce-specific command-line arguments to `diff-hl-mode'.
ORIG-FUN is the function being wrapped, ARGS are the arguments specified"
(let ((p4-lowlevel-diff-switches '("-du0")))
(apply orig-fun args)))
(with-eval-after-load 'vc-p4
(add-function :around (symbol-function 'diff-hl-changes-buffer)
#'oni:with-diff-hl-p4-args))
;; (with-eval-after-load 'server
;; (diminish 'server-buffer-clients
;; (propertize (concat " " (char-to-string #xf233))