Skip to content

PGP key generation

Terminal window
winget install -e --id Microsoft.Git
cd "C:\Program Files\Git"
.\git-bash.exe
Terminal window
sudo apt update && sudo apt install git
Terminal window
sudo pacman -Syu && sudo pacman -S git
Terminal window
apk update && apk add git
Terminal window
gpg --full-generate-key
Kind of key: 1 (RSA and RSA (default))
Keysize: 4096
Valid for: 0 (key does not expire)
Is this correct: y
Real name: your name or nickname
Email address: your email address
Comment:

You will see something like this:

You selected this USER-ID:
"Real name <Email@Address>"
Change (N)ame, (C)omment, (E)mail or (O)kay/(Q)uit?

If everything is correct, type O.

You will be asked to enter a passphrase. Choose a strong one and save it in a password manager.
Example of a strong passphrase: Catapult-Brewery-Hamstring4-Landfill-Visor-Slideshow.

Terminal window
gpg --armor --export-secret-keys Email@Address > private_key.asc
Terminal window
gpg --armor --export Email@Address > public_key.asc