1
0
Fork 0

Better handling of version format in relevant_versions()

This commit is contained in:
Félix Piédallu 2024-03-06 18:47:56 +01:00
parent 2353e4ccc1
commit 7f6c3a7123

View file

@ -274,7 +274,7 @@ class AppAutoUpdater:
elif tag.startswith("release-"): elif tag.startswith("release-"):
t_to_check = tag.split("-", 1)[-1].replace("-", ".") t_to_check = tag.split("-", 1)[-1].replace("-", ".")
if re.match(r"^v?[\d\.]*\-?\d$", t_to_check): if re.match(r"^v?\d+(\.\d+)*(\-\d+)?$", t_to_check):
return AppAutoUpdater.tag_to_int_tuple(t_to_check) return AppAutoUpdater.tag_to_int_tuple(t_to_check)
print(f"Ignoring tag {t_to_check}, doesn't look like a version number") print(f"Ignoring tag {t_to_check}, doesn't look like a version number")
return None return None