[calm - Cygwin server-side packaging maintenance script] branch master, updated. 20221205-8-gaec1dcf
Jon Turney
jturney@sourceware.org
Fri Jan 6 13:03:26 GMT 2023
https://sourceware.org/git/gitweb.cgi?p=cygwin-apps/calm.git;h=aec1dcf7af8df98df4c7ded84fd3a7a7750f9efd
commit aec1dcf7af8df98df4c7ded84fd3a7a7750f9efd
Author: Jon Turney <jon.turney@dronecode.org.uk>
Date: Sun Jul 10 15:54:47 2022 +0100
Allow package version to be marked as weakly retained
Allow a package version to be explicitly marked as weakly retained in
override.hint.
Ideally, we'd like something that let's us make a transaction that
removes a given source package and all install packages generated from
it, but we're not there yet...
Diff:
---
calm/hint.py | 1 +
calm/package.py | 10 ++++++++++
2 files changed, 11 insertions(+)
diff --git a/calm/hint.py b/calm/hint.py
index ddfcf74..6034c1d 100755
--- a/calm/hint.py
+++ b/calm/hint.py
@@ -93,6 +93,7 @@ hintkeys[override] = {
'keep-superseded-test': 'noval',
'disable-check': 'val',
'replace-versions': 'val',
+ 'noretain': 'val',
}
# valid categories
diff --git a/calm/package.py b/calm/package.py
index d3b5ab0..4538b8d 100755
--- a/calm/package.py
+++ b/calm/package.py
@@ -1529,6 +1529,16 @@ def stale_packages(packages):
mark = dep_so_age_mark
+ elif 'noretain' in po.override_hints:
+ def noretain_hint_mark(v):
+ noretain_versions = po.override_hints.get('noretain', '').split()
+ if (v in noretain_versions) or ('all' in noretain_versions):
+ return Freshness.conditional
+ else:
+ return Freshness.fresh
+
+ mark = noretain_hint_mark
+
# mark any versions explicitly listed in the keep: override hint (unconditionally)
for v in po.override_hints.get('keep', '').split():
if v in po.versions():
More information about the Cygwin-apps-cvs
mailing list