Skip to content

Add support for using external GPG instead of using built-in GPG #3997

Open
@realYulin

Description

@realYulin
  • I was not able to find an open or closed issue matching what I'm seeing

Setup

  • Which version of Git for Windows are you using? Is it 32-bit or 64-bit?
$ git --version --build-options

git version 2.37.2.windows.2
cpu: x86_64
built from commit: c5597badf94101f0076e6667edee120ab1ee5bac
sizeof-long: 4
sizeof-size_t: 8
shell-path: /bin/sh
feature: fsmonitor--daemon
  • Which version of Windows are you running? Vista, 7, 8, 10? Is it 32-bit or 64-bit?
$ cmd.exe /c ver

Microsoft Windows [Version 10.0.22622.586]
  • What options did you set as part of the installation? Or did you choose the
    defaults?
# One of the following:
> type "C:\Program Files\Git\etc\install-options.txt"
> type "C:\Program Files (x86)\Git\etc\install-options.txt"
> type "%USERPROFILE%\AppData\Local\Programs\Git\etc\install-options.txt"
> type "$env:USERPROFILE\AppData\Local\Programs\Git\etc\install-options.txt"
$ cat /etc/install-options.txt

Editor Option: VisualStudioCode
Custom Editor Path: 
Default Branch Option:  
Path Option: Cmd
SSH Option: ExternalOpenSSH
Tortoise Option: false
CURL Option: OpenSSL
CRLF Option: CRLFAlways
Bash Terminal Option: MinTTY
Git Pull Behavior Option: Merge
Use Credential Manager: Enabled
Performance Tweaks FSCache: Enabled
Enable Symlinks: Enabled
Enable Pseudo Console Support: Disabled
Enable FSMonitor: Disabled
  • Any other interesting things about your environment that might be related
    to the issue you're seeing?

None

Details

  • Which terminal/shell are you running Git from? e.g Bash/CMD/PowerShell/other

Windows PowerShell

Suggestion for installer
  • What did you expect to occur after running these commands?

The installer should ask which GPG executable should be used. I have installed Gpg4win and use it generate a GPG key, but Git’s GPG is not compatible to Gpg4win’s GPG (Gpg4win stores GPG keys at C:\Users\USERNAME\AppData\Roaming\gnupg while Git stores it at C:\Users\USERNAME\.gnupg). Because I have enabled the "gpgsign" config, I have to export the private key and reimport it at Git Bash.

  • What actually happened instead?

Git use its own GPG so when I commit, I can always see this error "gpg: key "xxxxxxxxxxxxxxxx" not found: Skipped"

  • If the problem was occurring with a specific repository, can you provide the
    URL to that repository to help us with testing?

None

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions