Enable GPG signing by default:
git config --global commit.gpgsign true
git config --global gpg.program (Get-Command gpg).Source
git config --global --unset gpg.format
gpg --list-secret-keys --keyid-format=long
git config --global user.signingkey B862284A2975BD3B!Install GPG for Windows:
winget install GnuPG.Gpg4winImport the private and public keys:
gpg --import .\B862284A2975BD3B.gpgNote, that for me, my primary key is
DC85D5DF95F8694, so the above command is importing my sub-key private keyB862284A2975BD3B.