apt-cache 命令詳解


apt-get 是 debian,ubuntu 發行版的包管理工具,與紅帽中的 yum 工具非常類似。

apt-get 命令一般需要 root 權限執行,所以一般跟著 sudo 命令。

基本用法     詳細用法

sudo apt-get xxxx
			

基本語法

apt-cache [-hvsn] [-o=config string] [-c=file] {[gencaches] | [showpkg pkg...] | [showsrc pkg...] | [stats] | [dump] |
 
          [dumpavail] | [unmet] | [search regex] | [show pkg...] | [depends pkg...] | [rdepends pkg...] |
 
          [pkgnames prefix] | [dotty pkg...] | [xvcg pkg...] | [policy pkgs...] | [madison pkgs...]}
			

詳細用法

命令 文字解釋 示例 示例解釋
apt-cache sta 顯示係統軟件包統計信息
p 展示搜索 string 關鍵詞相關軟件包 pt-cache search php5 展示搜索 php5 關鍵詞相關軟件包
apt-cache show packagenam 顯示軟件包的記錄信息 apt-cache show 顯示 less 軟件包的記錄信息
pt-cache showpkg packagenam 顯示軟件包的一些常規信息 pt-cache showp 顯示 less 軟件包的一些常規信息
apt-cache depends packagenam 查看 packagename 所依賴的軟件包
pt-cache rdepends packagenam 查看 packagename 被那些軟件包所依賴
apt-cache dump 顯示緩存中每個軟件包的簡要描述信息
pt-cache unm 展示不符閤一緻性的依賴關係
apt-cache pkgnam 列齣所有軟件包

 

版權聲明: 本文為獨傢原創稿件,版權歸 樂數軟件 ,未經許可不得轉載。