branch: externals/vc-got
commit 30dcedecffad644f77c4de56ad8817cd6ab02c03
Author: Omar Polo <[email protected]>
Commit: Omar Polo <[email protected]>
remove ``Summary'' from the commit
Emacs add this ``Summary: '' string. it's quite annoying. vc-git
doesn't seem to handle this specially, but maybe is git (the cli) that
trims it? I need to check. In the meantime, drop it.
---
vc-got.el | 7 ++++++-
1 file changed, 6 insertions(+), 1 deletion(-)
diff --git a/vc-got.el b/vc-got.el
index 1c0b612..860a9a2 100644
--- a/vc-got.el
+++ b/vc-got.el
@@ -371,7 +371,12 @@ DIR-OR-FILE."
(defun vc-got-checkin (files comment &optional _rev)
"Commit FILES with COMMENT as commit message."
(with-temp-buffer
- (apply #'vc-got--call "commit" "-m" comment files)))
+ (apply #'vc-got--call "commit" "-m"
+ ;; emacs add ``Summary:'' at the start of the commit
+ ;; message. vc-git doesn't seem to treat this specially.
+ ;; Since it's annoying, remove it.
+ (string-remove-prefix "Summary: " comment)
+ files)))
(defun vc-got-find-revision (file rev buffer)
"Fill BUFFER with the content of FILE in the given revision REV."