FreeBSD 中的 apt list 等價物是什麼?

FreeBSD 中的 apt list 等價物是什麼?

在遠離基於 *BSD 的系統(macOS 除外)幾年後,我剛剛再次開始使用 FreeBSD。我使用的是 FreeBSD 11.0 和 12.0。

管理包pkg看起來相當直觀,實際上指令非常相似pkg update,分別是pkg upgradepkg searchpkg autoremove

但是,擁有已安裝軟體包的清單相當於什麼apt listdpkg -l我記得並找到了一個詳細說明它的頁面pkg_info,但是該命令不起作用。

答案1

pkg_info用法已被棄用,因此您會感到困惑。

事實上,列出已安裝的 FreeBSD 軟體包的適當命令是pkg info

man pkg

info 顯示已安裝軟體包的資訊。

$ pkg info | tail
python27-2.7.13_1              Interpreted object-oriented programming language
readline-6.3.8                 Library for editing command lines as they are typed
screen-4.5.0_2                 Multi-screen window manager
sdig-0.45_1                    Translate IP/DNS/WINS/MAC address into port description
tmux-2.3_2                     Terminal Multiplexer
unbound-1.6.1                  Validating, recursive, and caching DNS resolver
vm-bhyve-1.1.5                 Management system for bhyve virtual machines
wget-1.19                      Retrieve files from the Net via HTTP(S) and FTP
xextproto-7.3.0                XExt extension headers
xproto-7.0.31                  X11 protocol headers

請參閱 FreeBSD wiki包裝底漆詳細說明了該指令的用法pkg以及已棄用的 pkg_* 指令的等效用法。

相關內容