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

Re: [PATCH] Add .gitconfig variable commit.gpg-sign

From
Michael J Gruber <git@drmicha.warpmail.net>
Date
Apr 23, 2013, 11:37 UTC
Message-ID
<51767290.2010208@drmicha.warpmail.net>
In-Reply-To
<CAASwCXcfCNqiMXD5JasTRKWZgCNsxnUY7k9E=f86xsTZjk37CA@mail.gmail.com>
Joel Jacobson venit, vidit, dixit 23.04.2013 02:00:
Show 34 quoted lines
> On Tue, Apr 23, 2013 at 12:43 AM, Junio C Hamano <gitster@pobox.com> wrote:
>> No docs?  No tests?
> 
> Maybe simply adding this text to git-commit.txt,
> 
> The default can be changed by the 'commit.gpg-sign' configuration
> variable (see linkgit:git-config[1]).
> 
> after,
> 
> -S[<keyid>]::
> --gpg-sign[=<keyid>]::
> GPG-sign commit.
> 
> would be sufficient?
> 
> Not sure what the proper way to test this,
> could you please suggest any other unit test I could look at for inspiration?
> 
>> As to the design, any regular configuration variable settings must
>> be overridable from the command line for a single invocation. Please
>> design an escape hatch in, for somebody who has this configuration
>> variable set, but does not want to sign this commit he is about to
>> make.
> 
> Something like --no-gpg-sign?
> 
>> Also do we generally use dash in the configuration variable names?
>> I thought the norm was section.CamelCase.
> 
> Since the command line long option is "gpg-sign", I thought it was best
> to use exactly the same term in the configuration variable name to
> avoid confusion. Is there any problem with dashes in variable names?
> 

Not really a problem, but as Junio writes, we don't use dashes in the config.

As for the command line override:

Don't we have "git -c commit.gpgsign=false" and such these days, so that we don't have to inflate options any more?

Michael
Previous: Joel JacobsonNext: Junio C Hamano
Message 3 of 15 in “Re: [PATCH] Add .gitconfig variable commit.gpg-sign”
  1. Junio C HamanoApr 22, 2013
  2. Joel JacobsonApr 23, 2013
  3. Michael J GruberApr 23, 2013
  4. Junio C HamanoApr 23, 2013
  5. Joel JacobsonApr 23, 2013
  6. Junio C HamanoApr 23, 2013
  7. Joel JacobsonApr 23, 2013
  8. Sebastian GötteApr 24, 2013
  9. Michael J GruberApr 24, 2013
  10. 1/1 templates: pre-push hook: check for missing GPG signatures (was: Re: [PATCH] Add .gitconfig variable commit.gpg-sign)Sebastian Götte, Apr 24, 2013
  11. Junio C HamanoApr 24, 2013
  12. 0/1 templates: pre-push hook: check for missing GPG signaturesSebastian Götte, Apr 25, 2013
  13. Junio C HamanoApr 25, 2013
  14. Junio C HamanoApr 23, 2013
  15. 1/1 templates: pre-push hook: check for missing GPG signaturesSebastian Götte, Apr 25, 2013

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.