From d462a9815f245f4dd846f842beb8bf27ee83755b Mon Sep 17 00:00:00 2001 From: Paul Robson Date: Sun, 4 Aug 2024 08:36:20 +0100 Subject: [PATCH] Fixed issue with no patch number --- firmware/common/scripts/prompt.py | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/firmware/common/scripts/prompt.py b/firmware/common/scripts/prompt.py index 2826bab5..1d358377 100644 --- a/firmware/common/scripts/prompt.py +++ b/firmware/common/scripts/prompt.py @@ -27,9 +27,8 @@ print("//\n//\tThis file is automatically generated\n//") print("#define PROMPT \"Morpheus Firmware: {0}\\r\"".format(version)) - -m = re.match("^v(\\d+)\\.(\\d+)\\-(\\d+).*$",plainVersion) -assert m is not None,"Cannot parse version string" +m = re.match("^v(\\d+)\\.(\\d+)\\-(\\d+).*$",plainVersion+"-0") +assert m is not None,"Cannot parse version string "+plainVersion print("#define VERSION_MAJOR ({0})".format(m.group(1))) print("#define VERSION_MINOR ({0})".format(m.group(2)))