且构网

分享程序员开发的那些事...
且构网 - 分享程序员编程开发的那些事

python apt-get列表升级

更新时间:2023-02-02 20:52:09

为什么不使用python-apt模块例如

Why not use the python-apt module eg.

import apt
cache=apt.Cache()
cache.update()
cache.open(None)
cache.upgrade()
for pkg in cache.getChanges():
    print pkg.sourcePackageName, pkg.isUpgradeable

还阅读了badp评论中的链接

also read the link in badp's comment