Skip to content

Commit f48e668

Browse files
committed
show separate message if on latest release
1 parent a4ad3fc commit f48e668

File tree

1 file changed

+8
-2
lines changed

1 file changed

+8
-2
lines changed

check_stbuehler_exchange_version

Lines changed: 8 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -567,15 +567,21 @@ def run_check(args: argparse.Namespace):
567567
print(f"CRITICAL: Version {owa_version} is outdated ({version_name})|")
568568
rc = 2
569569
if version and version.tree:
570-
print("Update targets:")
570+
update_targets: list[str] = []
571571
p = version.tree.parent
572572
previos_to = None
573573
while p:
574574
to = p.latest()
575575
if to != version and to != previos_to:
576-
print(f"- {to.short_code} ({to.name})")
576+
update_targets.append(f"- {to.short_code} ({to.name})")
577577
p = p.parent
578578
previos_to = to
579+
if update_targets:
580+
print("Update targets:")
581+
for t in update_targets:
582+
print(t)
583+
else:
584+
print("This is the latest release.")
579585
else:
580586
print(f"Acceptable versions: {', '.join(alive_versions)}")
581587
print("Also see:")

0 commit comments

Comments
 (0)