diff options
Diffstat (limited to '.config/emacs')
| -rw-r--r-- | .config/emacs/init.el | 16 |
1 files changed, 14 insertions, 2 deletions
diff --git a/.config/emacs/init.el b/.config/emacs/init.el index 8eaf534..024a276 100644 --- a/.config/emacs/init.el +++ b/.config/emacs/init.el @@ -437,6 +437,15 @@ list and require no escaping." (cl-return-from my/git-commit-maybe-set-fill-column (setq fill-column column)))))) +(defvar my/git-commit-use-changelog + (list 'my/emacs-repo-p)) + +(defun my/git-commit-maybe-set-changelog-support () + (let ((remotes (my/git-upstreams))) + (when (run-hook-with-args-until-success + 'my/git-commit-use-changelog remotes) + (git-commit-setup-changelog-support)))) + (defun my/revision-at-point () (cond ((derived-mode-p 'magit-mode) @@ -888,8 +897,11 @@ UPSTREAMS is a list of fetch URLs." (use-package git-commit :config (my/setopt-update-list - git-commit-setup-hook '(git-commit-turn-on-flyspell - my/git-commit-maybe-set-fill-column))) + git-commit-setup-hook + '(git-commit-turn-on-flyspell + my/git-commit-maybe-set-fill-column + my/git-commit-maybe-set-changelog-support) + '(git-commit-setup-changelog-support))) (use-package gnus :custom |
