Tag: add keys

Fastest PPA fixkey method yet

2 Comments

This is the fastest “safe” fixkey method around, since it does not involve aliasing which strictly speaking should be kept for shortening or modifying commands that you already have in your shell, nor does it update software sources, which can slow down valuable time, especially if you have a lot of them.
1. Create a new file named ‘fixkey’ at ‘/usr/bin’ with your favorite text editor:
sudo gedit /usr/bin/fixkey
Then, paste this code:
#! /bin/bash
echo please input your key
read KEY
apt-key adv --recv-keys --keyserver keyserver.ubuntu.com $KEY

2. Give the file executable privileges with this command:
sudo chmod +x /usr/bin/fixkey
3. Start fixing keys using the command line by typing ‘fixkey’ [wait for prompt] [key]. See example below:
fixkey
please input your key
XXXXXXXXXXX

5. You have just fixed a PPA key via the Linux command line!
Previous threads on this subject can be found here and here.
6. Now to fix the key for the chromium-daily ppa:
fixkey
please input your key
4E5E17B5

For a more inclusive but slower method of updating keys, you might like this script from Dominic Evans, which was first noted here. If you have a lot of keys that need to be updating then I suggest you use it, at least once.

If you like my method, please let me know.

Categories: BASH CLI Scripts Ubuntu

Tags: ,