* [PATCH] Documentation/commit-tree: mention -S option
@ 2013-03-25 19:39 Brad King
2013-03-25 20:06 ` Junio C Hamano
2013-03-25 20:39 ` Junio C Hamano
0 siblings, 2 replies; 5+ messages in thread
From: Brad King @ 2013-03-25 19:39 UTC (permalink / raw)
To: git; +Cc: gitster
Commit ba3c69a9 (commit: teach --gpg-sign option, 2011-10-05) added the
-S option and documented it in the command usage. Then commit 098bbdc3
(Add -S, --gpg-sign option to manpage of "git commit", 2012-10-21)
documented it in the porcelain manpage. Use wording from the porcelain
to document the option in the plumbing manpage too.
---
Documentation/git-commit-tree.txt | 7 ++++++-
1 file changed, 6 insertions(+), 1 deletion(-)
diff --git a/Documentation/git-commit-tree.txt b/Documentation/git-commit-tree.txt
index 86ef56e..62f7b53 100644
--- a/Documentation/git-commit-tree.txt
+++ b/Documentation/git-commit-tree.txt
@@ -10,7 +10,9 @@ SYNOPSIS
--------
[verse]
'git commit-tree' <tree> [(-p <parent>)...] < changelog
-'git commit-tree' [(-p <parent>)...] [(-m <message>)...] [(-F <file>)...] <tree>
+'git commit-tree' [(-p <parent>)...] [-S<keyid>] [(-m <message>)...]
+ [(-F <file>)...] <tree>
+
DESCRIPTION
-----------
@@ -52,6 +54,9 @@ OPTIONS
Read the commit log message from the given file. Use `-` to read
from the standard input.
+-S<keyid>::
+ GPG-sign commit.
+
Commit Information
------------------
--
1.7.10.4
^ permalink raw reply related [flat|nested] 5+ messages in thread
* Re: [PATCH] Documentation/commit-tree: mention -S option
2013-03-25 19:39 [PATCH] Documentation/commit-tree: mention -S option Brad King
@ 2013-03-25 20:06 ` Junio C Hamano
2013-03-25 20:15 ` Brad King
2013-03-25 20:39 ` Junio C Hamano
1 sibling, 1 reply; 5+ messages in thread
From: Junio C Hamano @ 2013-03-25 20:06 UTC (permalink / raw)
To: Brad King; +Cc: git
Brad King <brad.king@kitware.com> writes:
> Commit ba3c69a9 (commit: teach --gpg-sign option, 2011-10-05) added the
> -S option and documented it in the command usage. Then commit 098bbdc3
> (Add -S, --gpg-sign option to manpage of "git commit", 2012-10-21)
> documented it in the porcelain manpage. Use wording from the porcelain
> to document the option in the plumbing manpage too.
> ---
Thanks; sign-off?
> Documentation/git-commit-tree.txt | 7 ++++++-
> 1 file changed, 6 insertions(+), 1 deletion(-)
>
> diff --git a/Documentation/git-commit-tree.txt b/Documentation/git-commit-tree.txt
> index 86ef56e..62f7b53 100644
> --- a/Documentation/git-commit-tree.txt
> +++ b/Documentation/git-commit-tree.txt
> @@ -10,7 +10,9 @@ SYNOPSIS
> --------
> [verse]
> 'git commit-tree' <tree> [(-p <parent>)...] < changelog
> -'git commit-tree' [(-p <parent>)...] [(-m <message>)...] [(-F <file>)...] <tree>
> +'git commit-tree' [(-p <parent>)...] [-S<keyid>] [(-m <message>)...]
> + [(-F <file>)...] <tree>
> +
>
> DESCRIPTION
> -----------
> @@ -52,6 +54,9 @@ OPTIONS
> Read the commit log message from the given file. Use `-` to read
> from the standard input.
>
> +-S<keyid>::
> + GPG-sign commit.
> +
>
> Commit Information
> ------------------
^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: [PATCH] Documentation/commit-tree: mention -S option
2013-03-25 20:06 ` Junio C Hamano
@ 2013-03-25 20:15 ` Brad King
0 siblings, 0 replies; 5+ messages in thread
From: Brad King @ 2013-03-25 20:15 UTC (permalink / raw)
To: Junio C Hamano; +Cc: git
On 03/25/2013 04:06 PM, Junio C Hamano wrote:
> Brad King <brad.king@kitware.com> writes:
>
>> Commit ba3c69a9 (commit: teach --gpg-sign option, 2011-10-05) added the
>> -S option and documented it in the command usage. Then commit 098bbdc3
>> (Add -S, --gpg-sign option to manpage of "git commit", 2012-10-21)
>> documented it in the porcelain manpage. Use wording from the porcelain
>> to document the option in the plumbing manpage too.
>> ---
>
> Thanks; sign-off?
Oops!
Signed-off-by: Brad King <brad.king@kitware.com>
-Brad
^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: [PATCH] Documentation/commit-tree: mention -S option
2013-03-25 19:39 [PATCH] Documentation/commit-tree: mention -S option Brad King
2013-03-25 20:06 ` Junio C Hamano
@ 2013-03-25 20:39 ` Junio C Hamano
2013-03-25 21:00 ` [PATCH v2] commit-tree: document -S option consistently Brad King
1 sibling, 1 reply; 5+ messages in thread
From: Junio C Hamano @ 2013-03-25 20:39 UTC (permalink / raw)
To: Brad King; +Cc: git
Brad King <brad.king@kitware.com> writes:
> Commit ba3c69a9 (commit: teach --gpg-sign option, 2011-10-05) added the
> -S option and documented it in the command usage. Then commit 098bbdc3
> (Add -S, --gpg-sign option to manpage of "git commit", 2012-10-21)
> documented it in the porcelain manpage. Use wording from the porcelain
> to document the option in the plumbing manpage too.
> ---
This does not seem to use the same wording, though.
git commit -S
will pick up the signing key by calling get_signing_key() the same
way "git tag -s" would, iow, <keyid> part is optional.
> Documentation/git-commit-tree.txt | 7 ++++++-
> 1 file changed, 6 insertions(+), 1 deletion(-)
>
> diff --git a/Documentation/git-commit-tree.txt b/Documentation/git-commit-tree.txt
> index 86ef56e..62f7b53 100644
> --- a/Documentation/git-commit-tree.txt
> +++ b/Documentation/git-commit-tree.txt
> @@ -10,7 +10,9 @@ SYNOPSIS
> --------
> [verse]
> 'git commit-tree' <tree> [(-p <parent>)...] < changelog
> -'git commit-tree' [(-p <parent>)...] [(-m <message>)...] [(-F <file>)...] <tree>
> +'git commit-tree' [(-p <parent>)...] [-S<keyid>] [(-m <message>)...]
> + [(-F <file>)...] <tree>
> +
>
> DESCRIPTION
> -----------
> @@ -52,6 +54,9 @@ OPTIONS
> Read the commit log message from the given file. Use `-` to read
> from the standard input.
>
> +-S<keyid>::
> + GPG-sign commit.
> +
>
> Commit Information
> ------------------
^ permalink raw reply [flat|nested] 5+ messages in thread
* [PATCH v2] commit-tree: document -S option consistently
2013-03-25 20:39 ` Junio C Hamano
@ 2013-03-25 21:00 ` Brad King
0 siblings, 0 replies; 5+ messages in thread
From: Brad King @ 2013-03-25 21:00 UTC (permalink / raw)
To: git; +Cc: gitster
Commit ba3c69a9 (commit: teach --gpg-sign option, 2011-10-05) added the
-S option but documented it in the command usage without indicating that
the value is optional and forgot to mention it in the manpage. Later
commit 098bbdc3 (Add -S, --gpg-sign option to manpage of "git commit",
2012-10-21) documented the option in the porcelain manpage.
Use wording from the porcelain manpage to document the option in the
plumbing manpage. Also update the commit-tree usage summary to indicate
that the -S value is optional to be consistent with the manpage and with
the implementation.
Signed-off-by: Brad King <brad.king@kitware.com>
---
On 03/25/2013 04:39 PM, Junio C Hamano wrote:
> This does not seem to use the same wording, though.
>
> git commit -S
>
> will pick up the signing key by calling get_signing_key() the same
> way "git tag -s" would, iow, <keyid> part is optional.
Ahh, I was fooled by the commit-tree usage synopsis and didn't
read deeply enough into the implementation. Here is an updated
patch to cover that too.
Documentation/git-commit-tree.txt | 7 ++++++-
builtin/commit-tree.c | 2 +-
2 files changed, 7 insertions(+), 2 deletions(-)
diff --git a/Documentation/git-commit-tree.txt b/Documentation/git-commit-tree.txt
index 86ef56e..cafdc96 100644
--- a/Documentation/git-commit-tree.txt
+++ b/Documentation/git-commit-tree.txt
@@ -10,7 +10,9 @@ SYNOPSIS
--------
[verse]
'git commit-tree' <tree> [(-p <parent>)...] < changelog
-'git commit-tree' [(-p <parent>)...] [(-m <message>)...] [(-F <file>)...] <tree>
+'git commit-tree' [(-p <parent>)...] [-S[<keyid>]] [(-m <message>)...]
+ [(-F <file>)...] <tree>
+
DESCRIPTION
-----------
@@ -52,6 +54,9 @@ OPTIONS
Read the commit log message from the given file. Use `-` to read
from the standard input.
+-S[<keyid>]::
+ GPG-sign commit.
+
Commit Information
------------------
diff --git a/builtin/commit-tree.c b/builtin/commit-tree.c
index eac901a..f641ff2 100644
--- a/builtin/commit-tree.c
+++ b/builtin/commit-tree.c
@@ -10,7 +10,7 @@
#include "utf8.h"
#include "gpg-interface.h"
-static const char commit_tree_usage[] = "git commit-tree [(-p <sha1>)...] [-S<signer>] [-m <message>] [-F <file>] <sha1> <changelog";
+static const char commit_tree_usage[] = "git commit-tree [(-p <sha1>)...] [-S[<keyid>]] [-m <message>] [-F <file>] <sha1> <changelog";
static void new_parent(struct commit *parent, struct commit_list **parents_p)
{
--
1.7.10.4
^ permalink raw reply related [flat|nested] 5+ messages in thread
end of thread, other threads:[~2013-03-25 21:00 UTC | newest]
Thread overview: 5+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2013-03-25 19:39 [PATCH] Documentation/commit-tree: mention -S option Brad King
2013-03-25 20:06 ` Junio C Hamano
2013-03-25 20:15 ` Brad King
2013-03-25 20:39 ` Junio C Hamano
2013-03-25 21:00 ` [PATCH v2] commit-tree: document -S option consistently Brad King
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).