From 88bf62089636f81ca6280aee4d9a17d5a60f2f03 Mon Sep 17 00:00:00 2001 From: Ivo De Decker Date: Sun, 6 Sep 2015 15:21:30 +0000 Subject: [PATCH] Add option to ignore cruft Signed-off-by: Ivo De Decker --- britney.conf | 2 ++ britney.py | 15 ++++++++++++--- 2 files changed, 14 insertions(+), 3 deletions(-) diff --git a/britney.conf b/britney.conf index 39e2ca8..c579f63 100644 --- a/britney.conf +++ b/britney.conf @@ -59,3 +59,5 @@ HINTS_AUTO-REMOVALS = remove # naming a non-existent section will effectively disable new smooth # updates but still allow removals to occur SMOOTH_UPDATES = libs oldlibs + +IGNORE_CRUFT = 1 diff --git a/britney.py b/britney.py index 36dc546..fe65cc3 100755 --- a/britney.py +++ b/britney.py @@ -446,6 +446,9 @@ class Britney(object): self.options.architectures = [sys.intern(arch) for arch in arches] self.options.smooth_updates = self.options.smooth_updates.split() + if not hasattr(self.options, 'ignore_cruft') or \ + self.options.ignore_cruft == "0": + self.options.ignore_cruft = False def __log(self, msg, type="I"): """Print info messages according to verbosity level @@ -1471,13 +1474,19 @@ class Britney(object): if arch in self.options.fucked_arches: text = text + " (but %s isn't keeping up, so nevermind)" % (arch) else: - update_candidate = False - excuse.addreason("arch") - excuse.addreason("arch-%s" % arch) if uptodatebins: excuse.addreason("cruft-arch") excuse.addreason("cruft-arch-%s" % arch) + if self.options.ignore_cruft: + text = text + " (but ignoring cruft, so nevermind)" + else: + update_candidate = False + excuse.addreason("arch") + excuse.addreason("arch-%s" % arch) else: + update_candidate = False + excuse.addreason("arch") + excuse.addreason("arch-%s" % arch) excuse.addreason("build-arch") excuse.addreason("build-arch-%s" % arch)