git/list[1] front-page[2] threads[3] people[4] search[5] about
 

Re: [PATCH 2/2] replay: add the -S option

From
Patrick Steinhardt <ps@pks.im>
Date
Sep 28, 2026, 07:41 UTC
Message-ID
<aroaNcYqNIXcnQ-L@pks.im>
In-Reply-To
<20260925205348.1210154-3-pmonette@google.com>
On Fri, Sep 25, 2026 at 04:53:48PM -0400, Patrick Monette wrote:
Show 20 quoted lines
> diff --git a/builtin/replay.c b/builtin/replay.c
> index d39626a37d..87c628e2ed 100644
> --- a/builtin/replay.c
> +++ b/builtin/replay.c
> @@ -113,6 +113,16 @@ int cmd_replay(int argc,
>  			     PARSE_OPT_NONEG),
>  		OPT_BOOL(0, "linearize", &opts.linearize,
>  			 N_("drop merge commits, replaying only non-merge commits")),
> +		{
> +			.type = OPTION_STRING,
> +			.short_name = 'S',
> +			.long_name = "gpg-sign",
> +			.value = &opts.sign_commit,
> +			.argh = N_("key-id"),
> +			.help = N_("GPG-sign commits"),
> +			.flags = PARSE_OPT_OPTARG,
> +			.defval = (intptr_t) "",
> +		},
>  		OPT_END()
>  	};

Okay. We can't use `OPT_STRING()` or `OPT_STRING_F()` here because we want to set the default value.

I notice that we don't start to honor "commit.gpgSign". Is there a reason for this?

Patrick
Previous: Patrick MonetteNext: Junio C Hamano
Message 5 of 8 in “replay: add signing support”
  1. 0/2 replay: add signing supportPatrick Monette, Sep 25, 2026
  2. 1/2 replay: handle failure to create commitsPatrick Monette, Sep 25, 2026
  3. Patrick SteinhardtSep 28, 2026
  4. 2/2 replay: add the -S optionPatrick Monette, Sep 25, 2026
  5. Patrick SteinhardtSep 28, 2026
  6. Junio C HamanoOct 2, 2026
  7. Patrick SteinhardtSep 28, 2026
  8. Junio C HamanoSep 28, 2026

Read the whole thread, see it on lore, or plain text.

$ cat FOOTERMessages come from the public archive at lore.kernel.org/git, fetched every hour. The front page is chosen and written each morning by an AI editor and can be wrong; the threads themselves are the record. About and API. For agents: an MCP server at https://gitlist.dev/mcp, and any thread, story or person page as Markdown by adding .md to its URL (or sending Accept: text/markdown). Details in /llms.txt.