![列出可通过 APT 升级的软件包?](https://linux22.com/image/56134/%E5%88%97%E5%87%BA%E5%8F%AF%E9%80%9A%E8%BF%87%20APT%20%E5%8D%87%E7%BA%A7%E7%9A%84%E8%BD%AF%E4%BB%B6%E5%8C%85%EF%BC%9F.png)
运行后apt-get update
,我想获取所有可以升级的软件包的列表。
我opkg
通常是这样的::
opkg list_upgradable
我该如何使用 APT 来做到这一点?
答案1
该-u
开关显示可用于升级的软件包列表:
# apt-get -u upgrade
来自apt-get
联机帮助页:
-u
--显示升级
显示升级后的套餐;打印出所有要升级的软件包的列表。配置项:APT::Get::Show-Upgraded.
在更新任何内容之前,系统还会提示您。例如:
# apt-get -u upgrade
Reading Package Lists... Done
Building Dependency Tree... Done
The following packages have been kept back
cpp gcc lilo
The following packages will be upgraded
adduser ae apt autoconf debhelper dpkg-dev esound esound-common ftp indent
ipchains isapnptools libaudiofile-dev libaudiofile0 libesd0 libesd0-dev
libgtk1.2 libgtk1.2-dev liblockfile1 libnewt0 liborbit-dev liborbit0
libstdc++2.10-glibc2.2 libtiff3g libtiff3g-dev modconf orbit procps psmisc
29 packages upgraded, 0 newly installed, 0 to remove and 3 not upgraded.
Need to get 5055B/5055kB of archives. After unpacking 1161kB will be used.
Do you want to continue? [Y/n]