From e325517ed62aaafced0cf0639d4d06d56863f460 Mon Sep 17 00:00:00 2001 From: Faik Uygur Date: Mon, 2 Jul 2007 09:19:40 +0000 Subject: [PATCH] - handle reversed up... this is need for pm. ex: gaim -> pidgin ( gaim is replaced by pidgin in repository) So if gaim is installed... pisi lu shows gaim. All these upgrade gaim to pidgin: pisi up, pisi up gaim, pisi up pidgin --- pisi/operations.py | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/pisi/operations.py b/pisi/operations.py index 504ccf11..10870ee6 100644 --- a/pisi/operations.py +++ b/pisi/operations.py @@ -390,6 +390,15 @@ def upgrade_pkg_names(A = []): if x.endswith(ctx.const.package_suffix): ctx.ui.debug(_("Warning: package *name* ends with '.pisi'")) + # Handling of replacement packages + if x in replaces.values(): + Ap.append(x) + pkg = ctx.packagedb.get_package(x) + for r in pkg.replaces: + if pisi.replace.installed_package_replaced(r): + replaced.append(r.package) + continue + if x in replaces.keys(): Ap.append(replaces[x]) replaced.append(x)