为什么我无法添加任何 ppa 存储库?

为什么我无法添加任何 ppa 存储库?
karan@karan-HP-630-Notebook-PC:~$ sudo add-apt-repository ppa:danielrichter2007/grub-customizer
You are about to add the following PPA to your system:
 This PPA contains the latest release of Grub Customizer.


 More info: https://launchpad.net/~danielrichter2007/+archive/grub-customizer
Press [ENTER] to continue or ctrl-c to cancel adding it

Traceback (most recent call last):
  File "/usr/bin/add-apt-repository", line 177, in <module>
    if not sp.add_source_from_line(line):
  File "/usr/lib/python2.7/dist-packages/softwareproperties/SoftwareProperties.py", line 718, in add_source_from_line
    self.set_modified_sourceslist()
  File "/usr/lib/python2.7/dist-packages/softwareproperties/SoftwareProperties.py", line 471, in set_modified_sourceslist
    self.save_sourceslist()
  File "/usr/lib/python2.7/dist-packages/softwareproperties/SoftwareProperties.py", line 635, in save_sourceslist
    self.sourceslist.save()
  File "/usr/lib/python2.7/dist-packages/aptsources/sourceslist.py", line 396, in save
    files[source.file] = open(source.file, "w")
IOError: [Errno 2] No such file or directory: u'/etc/apt/sources.list.d//danielrichter2007-grub-customizer-precise.list'
Executing: gpg --ignore-time-conflict --no-options --no-default-keyring --secret-keyring /tmp/tmp.aGS8vrSgrk --trustdb-name /etc/apt/trustdb.gpg --keyring /etc/apt/trusted.gpg --primary-keyring /etc/apt/trusted.gpg --keyserver hkp://keyserver.ubuntu.com:80/ --recv 59DAD276B942642B1BBD0EACA8AA1FAA3F055C03
gpg: requesting key 3F055C03 from hkp server keyserver.ubuntu.com
gpg: key 3F055C03: "Launchpad PPA for Daniel Richter" not changed
gpg: Total number processed: 1
gpg:              unchanged: 1

答案1

读到最后一行:“Daniel Richter 的 Launchpad PPA”没有改变 gpg:处理总数:1 GPG:未改变:1

看起来 ppa 已经启用。尝试以下操作:

cat /etc/apt/sources.list.d/danielrichter2007-grub-customizer-precise.list

我启用了相同的 ppa,输出应该是这样的:

darent@helena:~$ cat /etc/apt/sources.list.d/danielrichter2007-grub-customizer-precise.list
deb http://ppa.launchpad.net/danielrichter2007/grub-customizer/ubuntu precise main #Grub Customizer PPA

祝你好运!

相关内容