相关疑难解决方法(0)

apt-get install with '-'(减号/连字符)删除包

我正在寻找一些包 ( nautilus-terminal),并且不小心这样做了:

$ sudo apt-get install nautilus-
Reading package lists... Done                                                                                                                                                                                                 
Building dependency tree                                                                                                                                                                                                      
Reading state information... Done                                                                                                                                                                                             
The following packages were automatically installed and are no longer required:                                                                                                                                               
  apturl apturl-common libgail-3-0 linux-headers-4.4.0-57 linux-headers-4.4.0-57-generic linux-image-4.4.0-57-generic linux-image-extra-4.4.0-57-generic                                                                      
Use 'sudo apt autoremove' to remove them.                                                                                                                                                                                     
The following packages will be REMOVED:                                                                                                                                                                                       
  gnome-session-flashback nautilus nautilus-sendto nautilus-share ubuntu-desktop                                                                                                                                              
0 upgraded, 0 newly installed, 5 to remove and 69 not upgraded.                                                                                                                                                               
After this operation, 2 031 kB disk space will be freed.                                                                                                                                                                      
Do …
Run Code Online (Sandbox Code Playgroud)

uninstall command-line apt

22
推荐指数
1
解决办法
2459
查看次数

“sudo apt-get install foo-” 导致删除 foo 包和所有依赖它的东西

在命令提示符下工作时,我不小心输入了以下命令:

sudo apt-get install python3-
Run Code Online (Sandbox Code Playgroud)

和 ubuntu 开始删除 python3 和所有依赖它的东西(包括 Firefox 等等)。幸运的是,我立即关闭了该终端并通过检查dpkg日志文件恢复了所有内容,但我想知道为什么install命令应该像删除一样?

这是一个错误吗?

考虑这样一种情况,您正在查找包名称(按 Tab 两次)并通过按 Enter 键来检查可能性,而这些 Enter 键保留在键盘缓冲区中,并且.... youhaaaa...apt-get正在删除整个安装你的眼睛。

command-line apt

10
推荐指数
2
解决办法
2777
查看次数

标签 统计

apt ×2

command-line ×2

uninstall ×1