gpg flags & options
-c, --symmetric
Encrypt a file with a symmetric cipher using a passphrase.
gpg -c secret.txt
-d, --decrypt
Decrypt an encrypted file and output to stdout.
gpg -d secret.txt.gpg
gpg -d secret.txt.gpg > secret.txt
--gen-key
Generate a new public/private key pair interactively.
gpg --gen-key
--import
Import a public or private key from a file.
gpg --import pubkey.asc
--export
Export a public key in binary format.
gpg --export user@example.com > pubkey.gpg
gpg --export -a user@example.com > pubkey.asc
--sign
Create a signature for a file.
gpg --sign document.pdf
--verify
Verify a signed file's signature.
gpg --verify document.pdf.gpg
gpg --verify signature.sig document.pdf
--list-keys
List all public keys in your keyring.
gpg --list-keys
gpg --list-keys user@example.com
-r, --recipient
Specify the recipient's key for encryption.
gpg -e -r user@example.com secret.txt
gpg -e -r alice@example.com -r bob@example.com secret.txt
-a, --armor
Output in ASCII-armored format instead of binary.
gpg -c -a secret.txt
gpg --export -a user@example.com