gpg: can't open `–': No such file or directory

Your only problem is that the dash after apt-key add is not the ASCII 0x2D hyphen character, but the Unicode U+2013 en dash. The former instructs apt-key to read the key from the standard input (where the preceding wget provides it through the pipe), while the latter is not treated specially, thus interpreted as a file name to read the key from. Unsurprisingly, such a file does not seem to exist in your current directory.


Use this:

wget -qO - http://www.dotdeb.org/dotdeb.gpg | apt-key add -

You need a space after the -O and the character after add seems to be wrong. -q turns off the output of wget.

Tags:

Debian

Apt