doomemacs/init/init-git.el

45 lines
1.5 KiB
EmacsLisp
Raw Normal View History

2014-08-30 10:37:25 +08:00
(use-package git-commit-mode
2014-08-10 07:25:06 +08:00
:mode (("/COMMIT_EDITMSG\\'" . git-commit-mode)
("/NOTES_EDITMSG\\'" . git-commit-mode)
("/MERGE_MSG\\'" . git-commit-mode)
("/TAG_EDITMSG\\'" . git-commit-mode)
("/PULLREQ_EDITMSG\\'" . git-commit-mode)))
2014-08-30 10:37:25 +08:00
(use-package git-rebase-mode
2014-08-10 07:25:06 +08:00
:mode ("/git-rebase-todo\\'" . git-rebase-mode))
2014-08-30 10:37:25 +08:00
(use-package gitconfig-mode
2014-08-10 07:25:06 +08:00
:mode (("/\\.gitconfig\\'" . gitconfig-mode)
("/\\.git/config\\'" . gitconfig-mode)
("/git/config\\'" . gitconfig-mode)
("/\\.gitmodules\\'" . gitconfig-mode))
:config (add-hook 'gitconfig-mode-hook 'flyspell-mode))
2014-08-30 10:37:25 +08:00
(use-package gitignore-mode
2014-08-10 07:25:06 +08:00
:mode (("/\\.gitignore\\'" . gitignore-mode)
("/\\.git/info/exclude\\'" . gitignore-mode)
("/git/ignore\\'" . gitignore-mode)))
2014-08-30 10:37:25 +08:00
(use-package git-gutter-fringe
2014-08-10 07:25:06 +08:00
:diminish git-gutter-mode
:init
(progn
(global-git-gutter-mode t)
(add-hook 'git-gutter-mode-on-hook
(lambda() (fringe-mode '(4 . 8)))))
:config
(progn
(custom-set-variables '(git-gutter:lighter " !"))
(custom-set-variables '(git-gutter:verbosity 0))
2014-08-13 12:24:22 +08:00
(set-face-foreground 'git-gutter-fr:modified "#444444")
2014-08-10 07:25:06 +08:00
(set-face-background 'git-gutter-fr:modified "#444444")
2014-08-13 12:24:22 +08:00
(set-face-foreground 'git-gutter-fr:deleted "#884444")
2014-08-10 07:25:06 +08:00
(set-face-background 'git-gutter-fr:deleted "#884444")
2014-08-13 12:24:22 +08:00
(set-face-foreground 'git-gutter-fr:added "#448844")
2014-08-10 07:25:06 +08:00
(set-face-background 'git-gutter-fr:added "#448844")
))
2014-08-08 06:35:22 +08:00
;;
(provide 'init-git)