From c412100ebd0001c02920a9a31f5ea26f7c94d262 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Tom=C3=A1s=20Touceda?= Date: Sat, 3 Sep 2011 22:54:00 -0300 Subject: Try to install only if isReady Also, it removes a bunch of code for non-thp packages. --- lib/thandy/ClientCLI.py | 23 +++-------------------- 1 file changed, 3 insertions(+), 20 deletions(-) diff --git a/lib/thandy/ClientCLI.py b/lib/thandy/ClientCLI.py index 828d853..aa60205 100755 --- a/lib/thandy/ClientCLI.py +++ b/lib/thandy/ClientCLI.py @@ -138,33 +138,16 @@ def update(args): files.add("/meta/timestamp.txt") forceCheck = False - if (thpTransactions or installable) and not files: - # for p, d in installable.items(): - # for n, i in d.items(): - # if i.canInstall(): - # logCtrl("CAN_INSTALL", PKG=p, ITEM=n) - # else: - # logCtrl("NO_INSTALL", PKG=p, ITEM=n) - # i.setCacheRoot(repoRoot) - - # logging.info("Ready to install packages for files: %s", - # ", ".join(sorted(installable.keys()))) - # if install: - # # XXXX handle ordering - # for p in installable.values(): - # for h in p.values(): - # i = h.getInstaller() - # if i != None: - # i.install() - + if thpTransactions and not files: for bundle in thpTransactions: tr = thandy.packagesys.ThpPackages.ThpTransaction(thpTransactions[bundle], alreadyInstalled, repoRoot) if tr.isReady(): logCtrl("READY", BUNDLE=bundle) - if install: + if install and tr.isReady(): tr.install() + logCtrl("INSTALLED", BUNDLE=bundle) return -- cgit v1.2.3