为什么安装一个 unity-scope 会删除 ubuntu-desktop?

gun*_*ert 14 package-management apt dependencies

我想安装unity-scope-github但遇到了一个令人惊讶的问题

The following package was automatically installed and is no longer required:
session-shortcuts
Use 'sudo apt autoremove' to remove it.
The following packages will be REMOVED:
  ubuntu-desktop unity unity-scope-home unity-tweak-tool
The following NEW packages will be installed:
  unity-scope-github
Run Code Online (Sandbox Code Playgroud)

现在这可能是一些旧的/未积极维护的包中的一个错误,一旦我理解了这个问题就会报告。

我真正的问题是:我怎么知道为什么apt会得出安装一个额外范围需要删除两个有用的元包和unity-scope-home.

这是否表明数据库中存在问题?


Annotation:session-shortcuts仅在我尝试安装时“不再需要” unity-scope-github,在此之前sudo apt autoremove根本不会产生任何结果。


我知道 unity-scope-github 已经很老了/没有积极维护,没有它我可以而且会过得很好

Rav*_*ina 25

如果你没有安装 aptitude,请安装它:

sudo apt install aptitude
Run Code Online (Sandbox Code Playgroud)

然后运行:

aptitude why-not unity-scope-github
Run Code Online (Sandbox Code Playgroud)

它会给你一个输出,如:

i   unity            Depends   unity-scope-home  
i A unity-scope-home Conflicts unity-scope-github
Run Code Online (Sandbox Code Playgroud)

所以我们可以看到,unity依赖于unity-scope-home,并且与unity-scope-home相冲突unity-scope-github

您的其他软件包也是这些依赖项的一部分,例如:如果您运行:

apt-cache depends unity-tweak-tool
Run Code Online (Sandbox Code Playgroud)

你会发现这取决于unity.

关于session-shortcuts, 如果你运行:

apt-cache rdepends session-shortcuts
Run Code Online (Sandbox Code Playgroud)

你会得到:

session-shortcuts
Reverse Depends:
  unity
  unity
Run Code Online (Sandbox Code Playgroud)

这意味着这个包是由 unity 安装的,现在 unity 将被删除,你不再需要它了。