如何在ubuntu中查看包的所有嵌套依赖项?

问题描述 投票:0回答:1

有人能让我知道如何在Ubuntu中查看包的所有嵌套依赖项?例如,

support@vrni-platform:/tmp$ sudo apt-cache depends hadoop-yarn-resourcemanager
hadoop-yarn-resourcemanager
  Depends: hadoop-yarn

support@vrni-platform:/tmp$ sudo apt-cache depends hadoop-yarn
hadoop-yarn
  Depends: libc6
  Depends: adduser
  Depends: bigtop-utils
  Depends: hadoop
  Depends: avro-libs
  Depends: zookeeper

我正在寻找类似下面的东西。有点类似于mvn dependency:tree

hadoop-yarn-resourcemanager
  Depends: hadoop-yarn
     Depends: libc6
     Depends: adduser
     Depends: bigtop-utils
     Depends: hadoop
     Depends: avro-libs
     Depends: zookeeper

我见过这个question,但我正在寻找完整的依赖树。

linux ubuntu
1个回答
0
投票

好吧,有apt-cache dotty命令,它将生成包的依赖关系的graphviz表示。然而,这并没有你想象的那么有用:几乎所有东西都需要很多“核心包”,结果图会非常大。

例如,apt-cache dotty openssh-client的输出呈现为this beast

点语法相对简单;您可以自己解析它以提取信息的子集。

© www.soinside.com 2019 - 2024. All rights reserved.