{"thread":{"id":"1529","subject":"[PATCH] Make git-format-patch's signoff option more consistent","startedAt":"2005-08-16T00:20:34Z","lastAt":"2005-08-16T00:20:34Z","messageCount":1,"participants":["Johannes Schindelin"],"isPatch":true,"patchVersion":1,"patchTotal":null},"messages":[{"id":"7331","messageId":"Pine.LNX.4.63.0508160208020.26580@wgmdd8.biozentrum.uni-wuerzburg.de","threadId":"1529","inReplyTo":null,"subject":"[PATCH] Make git-format-patch's signoff option more consistent","fromName":"Johannes Schindelin","fromEmail":"johannes.schindelin@gmx.de","sentAt":"2005-08-16T00:20:34Z","receivedAt":"2005-08-16T00:20:34Z","isPatch":true,"sender":{"key":"johannes.schindelin@gmx.de","avatar":"https://avatars.githubusercontent.com/u/127790?v=4"},"body":"\nSince git-commit-script has a \"--signoff\" option, use that in \ngit-format-patch-script, too (and since partial option names are \nsupported,\"--sign\" is still valid).\n\nAlso, if the message already contains the S-O-B line, silently ignore the \n\"--signoff\" request.\n\nSigned-off-by: Johannes Schindelin <Johannes.Schindelin@gmx.de>\n---\n\n git-format-patch-script |   13 ++++++++-----\n 1 files changed, 8 insertions(+), 5 deletions(-)\n\n36d8f8116e677848da231e3d33da379bd4546505\ndiff --git a/git-format-patch-script b/git-format-patch-script\n--- a/git-format-patch-script\n+++ b/git-format-patch-script\n@@ -6,7 +6,7 @@\n . git-sh-setup-script || die \"Not a git archive.\"\n \n usage () {\n-    echo >&2 \"usage: $0\"' [-n] [-o dir] [--mbox] [--check] [--sign] [-<diff options>...] upstream [ our-head ]\n+    echo >&2 \"usage: $0\"' [-n] [-o dir] [--mbox] [--check] [--signoff] [-<diff options>...] upstream [ our-head ]\n \n Prepare each commit with its patch since our-head forked from upstream,\n one file per patch, for e-mail submission.  Each output file is\n@@ -46,7 +46,7 @@ do\n     date=t author=t mbox=t ;;\n     -n|--n|--nu|--num|--numb|--numbe|--number|--numbere|--numbered)\n     numbered=t ;;\n-    -s|--s|--si|--sig|--sign)\n+    -s|--s|--si|--sig|--sign|--signo|--signof|--signoff)\n     signoff=t ;;\n     -o=*|--o=*|--ou=*|--out=*|--outp=*|--outpu=*|--output=*|--output-=*|\\\n     --output-d=*|--output-di=*|--output-dir=*|--output-dire=*|\\\n@@ -179,9 +179,12 @@ Date: '\"$ad\"\n \n \ttest \"$signoff\" = \"t\" && {\n \t\toffsigner=`git-var GIT_COMMITTER_IDENT | sed -e 's/>.*/>/'`\n-\t\techo\n-\t\techo \"Signed-off-by: $offsigner\"\n-\t\techo\n+\t\tline=\"Signed-off-by: $offsigner\"\n+\t\tgrep -q \"^$line\\$\" $commsg || {\n+\t\t\techo\n+\t\t\techo \"$line\"\n+\t\t\techo\n+\t\t}\n \t}\n \n \techo '---'\n"}]}