about summary refs log tree commit diff stats
path: root/emacs-prelude/personal/lisp/init-git.el
diff options
context:
space:
mode:
authorDavid Morgan <djm_uk@protonmail.com>2021-08-05 07:47:38 +0100
committerDavid Morgan <djm_uk@protonmail.com>2021-08-05 07:47:38 +0100
commitfd87e0ed4c52bed31798c0f83f8f121d2659f869 (patch)
tree636db2b3ec071e0fc75aaa2fdf2644da7f2f74e9 /emacs-prelude/personal/lisp/init-git.el
parent1190ad9a1882344e9046277ca50f306c82e8cc9b (diff)
downloaddotfiles-fd87e0ed4c52bed31798c0f83f8f121d2659f869.tar.gz
Play around with a few things
Diffstat (limited to 'emacs-prelude/personal/lisp/init-git.el')
-rw-r--r--emacs-prelude/personal/lisp/init-git.el26
1 files changed, 19 insertions, 7 deletions
diff --git a/emacs-prelude/personal/lisp/init-git.el b/emacs-prelude/personal/lisp/init-git.el
index ac5ce4b..7745af8 100644
--- a/emacs-prelude/personal/lisp/init-git.el
+++ b/emacs-prelude/personal/lisp/init-git.el
@@ -8,16 +8,28 @@
   (defun my/magit-refresh-state ()
     (interactive)
     (dolist (buf (buffer-list))
-            (when (and (not (buffer-modified-p buf))
-                       (buffer-file-name buf)
-                       (file-exists-p (buffer-file-name buf))
-                       (file-in-directory-p (buffer-file-name buf) (magit-toplevel)))
-              (with-current-buffer buf
-                (vc-refresh-state)))))
+      (when (and (not (buffer-modified-p buf))
+                 (buffer-file-name buf)
+                 (file-exists-p (buffer-file-name buf))
+                 (file-in-directory-p (buffer-file-name buf) (magit-toplevel)))
+        (with-current-buffer buf
+          (vc-refresh-state)))))
   :config
   (key-chord-define-global "UU" 'my/magit-set-upstream)
   (key-chord-define-global "RR" 'my/magit-refresh-state)
-  :custom (magit-diff-refine-hunk 'all))
+  :custom-face
+  (diff-added ((t (:foreground "green4"))))
+  (magit-diff-added ((t (:foreground "green4"))))
+  (magit-diff-added-highlight ((t (:foreground "green4"))))
+  (diff-removed ((t (:foreground "red3"))))
+  (magit-diff-removed ((t (:foreground "red3"))))
+  (magit-diff-removed-highlight ((t (:foreground "red3"))))
+  :custom
+  (magit-diff-refine-hunk 'all)
+  (magit-diff-paint-whitespace t)
+  (magit-diff-paint-whitespace-lines 'all)
+  (magit-diff-highlight-trailing t)
+  (magit-diff-highlight-indentation t))
 
 (prelude-require-package 'forge)
 (use-package forge