도도다다

[Git] Signing commits with GPG

2021. 6. 2. 00:24 | 개발 관련

globally set up

git config --global commit.gpgsign true

▲ Turn on gpg signing commits globally

 

> gpg --list-keys

/c/Users/doda/.gnupg/pubring.kbx
--------------------------------
pub   rsa4096 2020-02-14 [SC] [expires: 2036-02-10]
      A**************************************
uid           [ unknown] Dohyun Jung <****@****.***>
uid           [ unknown] Dohyun Jung <****@****.***>
uid           [ unknown] Dohyun Jung <****@****.***>
sub   rsa4096 2020-02-14 [E] [expires: 2036-02-10]

▲ Copy the "*****" value below the "pub" (this is your own)

 

git config --global user.signingkey *******

▲ Paste the copied value into "*******"