• ᴥ •つ TOP

Check your existing GPG keys and get the key which you want to update the email.

$ gpg --list-secret-keys --keyid-format=long sec ed25519/3AA5C34371567BD2 2024-03-04 [SC] uid [ultimate] Jii <rolemadelen@tuta.io> ssb cv25519/4BB6D45482678BE3 2024-03-04 [E]

In this case, we'll use the key 3AA5C34371567BD2.

Enter the following command to edit the key.

gpg --edit-key 3AA5C34371567BD2

Then the you'll be in gpg prompt session waiting for you to type a command. Type adduid to add the new (or corrected) author name and the email.

gpg> adduid

Then, use deluid to remove the old. You first need to select the user ID.

$ gpg --edit-key 3AA5C34371567BD2 $ >gpg 1 # choose user ID (1) sec ed25519/3AA5C34371567BD2 created: 2024-03-04 expires: never usage: SC trust: ultimate validity: ultimate ssb cv25519/4BB6D45482678BE3 created: 2024-03-04 expires: never usage: E [ultimate] (1)*. OLD NAME <OLD EMAIL> [ unknown] (2). NEW NAME <NEW EMAIL> $ >gpg deluid

You end up with an updated name and the email. One last thing you need to do is configure how much you trust this key.

$ >gpg 2 # choose the new user ID (2) $ >gpg trust
Please decide how far you trust this user to correctly verify other users' keys (by looking at passports, checking fingerprints from different sources, etc.) 1 = I don't know or won't say 2 = I do NOT trust 3 = I trust marginally 4 = I trust fully 5 = I trust ultimately m = back to the main menu Your decision? 5
← prev postnext post →