git.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: exon@op5.se (Andreas Ericsson)
To: git@vger.kernel.org
Subject: [PATCH] git-commit: Having $GIT_COMMITTER_NAME implies -s
Date: Thu, 17 Nov 2005 00:38:29 +0100 (CET)	[thread overview]
Message-ID: <20051116233829.0B3C55BA81@nox.op5.se> (raw)


I've been trying, in vain, to tell my colleagues to use the -s flag.
With this patch I can at least fix up their .profile's myself.

Signed-off-by: Andreas Ericsson <ae@op5.se>

---

 git-commit.sh |    6 ++----
 1 files changed, 2 insertions(+), 4 deletions(-)

applies-to: a2fe76123d6f5b835d3312a70a02ed4d07e25f8e
d32c78570e25a9718721937b1ee9051e950ad1fd
diff --git a/git-commit.sh b/git-commit.sh
index 41955e8..ff9502c 100755
--- a/git-commit.sh
+++ b/git-commit.sh
@@ -134,8 +134,7 @@ then
 	cat "$GIT_DIR/MERGE_MSG"
 fi | git-stripspace >"$GIT_DIR"/COMMIT_EDITMSG
 
-case "$signoff" in
-t)
+if [ "$signoff" = t -o "$GIT_COMMITTER_NAME" ]; then
 	{
 		echo
 		git-var GIT_COMMITTER_IDENT | sed -e '
@@ -143,8 +142,7 @@ t)
 			s/^/Signed-off-by: /
 		'
 	} >>"$GIT_DIR"/COMMIT_EDITMSG
-	;;
-esac
+fi
 
 if [ -f "$GIT_DIR/MERGE_HEAD" ]; then
 	echo "#"
---
0.99.9.GIT

             reply	other threads:[~2005-11-16 23:44 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2005-11-16 23:38 Andreas Ericsson [this message]
2005-11-17  4:28 ` [PATCH] git-commit: Having $GIT_COMMITTER_NAME implies -s Junio C Hamano
2005-11-17  5:27   ` H. Peter Anvin

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20051116233829.0B3C55BA81@nox.op5.se \
    --to=exon@op5.se \
    --cc=git@vger.kernel.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).