如何在支持的Ubuntu版本中访问宇宙软件源?
sudo add-apt-repository universe
sudo add-apt-repository "deb http://archive.ubuntu.com/ubuntu $(lsb_release -sc) universe"
sudo add-apt-repository "deb http://archive.ubuntu.com/ubuntu $(lsb_release -sc) main universe restricted multiverse"
sudo add-apt-repository "deb http://archive.canonical.com/ubuntu $(lsb_release -sc) partner"
sudo apt-get update
p.s.
$(lsb_release -sc)
检查你的Ubuntu版本并将其名称放在源链接中。由于12.04被称为precise
,你可以在终端中测试lsb_release -sc
是否给出precise
。这样就会在软件源中添加你的Ubuntu发行版的确切名称。如果单词错误,什么都不会起作用。
有关存储库的所有差异,请阅读https://help.ubuntu.com/community/Repositories/Ubuntu
sudo apt-get update
命令。 - ty01sudo add-apt-repository main
sudo add-apt-repository universe
sudo add-apt-repository multiverse
sudo add-apt-repository restricted
sudo apt-get update
$ sudo add-apt-repository main
“main”发行组件已经对所有源启用。
- Muhammad Ali