Skip to content

Instantly share code, notes, and snippets.

@japalekhin
Last active May 25, 2021 08:52
Show Gist options
  • Save japalekhin/aa441da70758dff180020c6a0dac48eb to your computer and use it in GitHub Desktop.
Save japalekhin/aa441da70758dff180020c6a0dac48eb to your computer and use it in GitHub Desktop.

Identity

git config --global user.name "Firstname Lastname"
git config --global user.email "[email protected]"

For other repos using other name/email:

git config user.name "Firstname Lastname"
git config user.email "[email protected]"

Signing

gpg --full-generate-key
gpg --list-secret-keys --keyid-format LONG

Copy sec rsaNNNN/{thispart} 2021-05-25 [SC] and remember it as PRIVATE_KEY.

gpg --armor --export PRIVATE_KEY

Copy the public GPG key and add it to Github.

git config --global user.signingkey PRIVATE_KEY

Singing without -S

git config --global commit.gpgsign true
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment