GPG
2020/06/29 by jean tran
Install GPG
Generate a GPG Key
Run the following command:
A prompt ask you to choose between 1-4 key type:
It is recommended to choose at least
4096
:
Specify GPG key expiration:
Asking for confirmation (y/N):
Double checking your info to validate or edit:
Listing GPG Keys:
It will prompt information such as the following:
Export public key ID
Copy the value equivalent of BC4F4B77228120E9
(replace your key ID as listed on step6)
Signing git commits
Add the ID to your Git configuration file
config
or.gitconfig
(example:BC4F4B77228120E9
):
Commit can be signed by adding the following
-S
flag
Case if you don't want to bother with
-S
flag
Tips & Tricks
For OSX add the following command on your .<type>rc
file. (.bashrc
| .zshrc
)
Last updated
Was this helpful?