From 3bebabda125559dfacc1e1107e23e97d0cf41e11 Mon Sep 17 00:00:00 2001 From: Mike Khiretskiy Date: Fri, 10 Apr 2015 10:32:59 +0300 Subject: [PATCH] =?UTF-8?q?=D0=94=D0=BE=D0=B1=D0=B0=D0=B2=D0=BB=D0=B5?= =?UTF-8?q?=D0=BD=D0=BE=20=D0=BE=D0=B1=D0=BD=D0=BE=D0=B2=D0=BB=D0=B5=D0=BD?= =?UTF-8?q?=D0=B8=D0=B5=20=D0=BA=D1=8D=D1=88=D0=B0=20=D0=BD=D0=B0=D1=81?= =?UTF-8?q?=D1=82=D1=80=D0=B0=D0=B8=D0=B2=D0=B0=D0=B5=D0=BC=D1=8B=D1=85=20?= =?UTF-8?q?=D0=BF=D0=B0=D0=BA=D0=B5=D1=82=D0=BE=D0=B2=20=D0=BF=D0=BE=D1=81?= =?UTF-8?q?=D0=BB=D0=B5=20=D1=81=D0=B8=D0=BD=D1=85=D1=80=D0=BE=D0=BD=D0=B8?= =?UTF-8?q?=D0=B7=D0=B0=D1=86=D0=B8=D0=B8?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- pym/update/update.py | 6 ++++++ pym/update/utils/cl_update.py | 6 ++++++ 2 files changed, 12 insertions(+) diff --git a/pym/update/update.py b/pym/update/update.py index 3c92c7e..aa81fc9 100644 --- a/pym/update/update.py +++ b/pym/update/update.py @@ -20,6 +20,7 @@ from os import path import os import time from calculate.core.server.gen_pid import search_worked_process +from calculate.core.setup_cache import Cache as SetupCache from calculate.lib.cl_template import SystemIni from calculate.lib.datavars import DataVarsError @@ -1046,3 +1047,8 @@ class Update(object): except OSError: pass return True + + def updateSetupCache(self): + cache = SetupCache(self.clVars) + cache.update(force=True) + return True diff --git a/pym/update/utils/cl_update.py b/pym/update/utils/cl_update.py index c13a202..0a4bdbc 100644 --- a/pym/update/utils/cl_update.py +++ b/pym/update/utils/cl_update.py @@ -239,6 +239,12 @@ class ClUpdateAction(Action): Get('cl_update_eixupdate_force') != 'skip' or Get('cl_update_eixupdate_force') == 'force')) }, + {'name': 'update_setup_cache', + 'message': __("Updating the package setup cache"), + 'method': 'Update.updateSetupCache()', + 'essential': False, + 'condition': lambda Get: Get('cl_update_outdate_set') == 'on' + }, {'name': 'sync_reps:cleanpkg', 'message': __("Removing obsolete distfiles and binary packages"), 'method': 'Update.cleanpkg()',