apt-cache用来做什么?


Answers:


18

apt-cache 是用于在apt的缓存中操作并从软件包中获取信息的命令。

它创建了一个可从源列表中获得的有关软件包信息的信息库,因此您可以通过这种方式搜索软件包及其相关信息。

假设您要安装聊天程序,但不知道该程序包的名称。

您将打开一个控制台并输入:

sudo apt-cache search chat

这将返回可用软件包的列表,这些软件包涉及“ 聊天 ”一词。

典型操作apt-cache

apt-cache add

将程序包文件添加到源缓存。

apt-cache gencaches

构建包和源缓存

apt-cache showpkg

显示单个包装的一些常规信息

apt-cache stats

显示一些基本统计数据

apt-cache dump

以简洁的形式显示整个文件

apt-cache dumpavail

将可用文件打印到标准输出

apt-cache unmet

显示未满足的依赖关系

apt-cache check

检查一下缓存

apt-cache search

在软件包列表中搜索正则表达式模式

apt-cache show

显示包裹的可读记录

apt-cache depends

显示包的原始依赖项信息

apt-cache pkgnames

列出所有软件包的名称

apt-cache dotty

生成GraphVis的软件包图

不要忘记在上面列出的命令后添加软件包名称。

来源1

来源2

By using our site, you acknowledge that you have read and understand our Cookie Policy and Privacy Policy.
Licensed under cc by-sa 3.0 with attribution required.