If `git-append-signed-off-by' is non-nil, automatically append a
sign-off line to the log message when editing it.
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
Signed-off-by: Junio C Hamano <junkio@cox.net>
maint
Alexandre Julliard19 years agocommitted byJunio C Hamano
@ -103,6 +102,9 @@ If not set, fall back to `add-log-mailing-address' and then `user-mail-address'.
@@ -103,6 +102,9 @@ If not set, fall back to `add-log-mailing-address' and then `user-mail-address'.
(defvar git-commits-coding-system 'utf-8
"Default coding system for git commits.")
(defvar git-append-signed-off-by nil
"Whether to append a Signed-off-by line to the commit message.")
(defconst git-log-msg-separator "--- log message follows this line ---")
(defconst git-per-dir-ignore-file ".gitignore"
@ -792,7 +794,8 @@ If not set, fall back to `add-log-mailing-address' and then `user-mail-address'.
@@ -792,7 +794,8 @@ If not set, fall back to `add-log-mailing-address' and then `user-mail-address'.
(unless git-status (error "Not in git-status buffer."))
(let ((buffer (get-buffer-create "*git-commit*"))
(merge-heads (git-get-merge-heads))
(dir default-directory))
(dir default-directory)
(sign-off git-append-signed-off-by))
(with-current-buffer buffer
(when (eq 0 (buffer-size))
(cd dir)
@ -809,10 +812,13 @@ If not set, fall back to `add-log-mailing-address' and then `user-mail-address'.
@@ -809,10 +812,13 @@ If not set, fall back to `add-log-mailing-address' and then `user-mail-address'.