[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[nongnu] elpa/git-commit 7293a80a5c 2/4: git-commit-setup: Cosmetic rear
From: |
ELPA Syncer |
Subject: |
[nongnu] elpa/git-commit 7293a80a5c 2/4: git-commit-setup: Cosmetic rearrangement |
Date: |
Mon, 29 Apr 2024 10:00:40 -0400 (EDT) |
branch: elpa/git-commit
commit 7293a80a5ce12cf83ef8596d0e1f378902944339
Author: Jonas Bernoulli <jonas@bernoul.li>
Commit: Jonas Bernoulli <jonas@bernoul.li>
git-commit-setup: Cosmetic rearrangement
It makes sense for the usage message to be handled last and for the
header-line setup (which also provides usage information), to be placed
next to that (but not after that, as was the case before).
Doing these thing *after* running the hook (as we already did) makes
sense, since that makes it possible to use the hook to tweak the
information.
---
lisp/git-commit.el | 8 ++++----
1 file changed, 4 insertions(+), 4 deletions(-)
diff --git a/lisp/git-commit.el b/lisp/git-commit.el
index ad672a6b35..8bc902d906 100644
--- a/lisp/git-commit.el
+++ b/lisp/git-commit.el
@@ -660,13 +660,13 @@ Used as the local value of `header-line-format', in
buffer using
(git-commit-mode 1))
(with-demoted-errors "Error running git-commit-setup-hook: %S"
(run-hooks 'git-commit-setup-hook))
- (when git-commit-usage-message
- (setq with-editor-usage-message git-commit-usage-message))
- (with-editor-usage-message)
+ (set-buffer-modified-p nil)
(when-let ((format git-commit-header-line-format))
(setq header-line-format
(if (stringp format) (substitute-command-keys format) format)))
- (set-buffer-modified-p nil))
+ (when git-commit-usage-message
+ (setq with-editor-usage-message git-commit-usage-message))
+ (with-editor-usage-message))
(defun git-commit-run-post-finish-hook (previous)
(when (and git-commit-post-finish-hook