From d80861db3720f2c185833def57a1b5a7855aa150 Mon Sep 17 00:00:00 2001 From: Bertrand Songis Date: Wed, 13 Sep 2017 18:43:01 +0200 Subject: [PATCH] Nightly build enabled when suffix starts with 'N' --- radio/util/build-firmware.py | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/radio/util/build-firmware.py b/radio/util/build-firmware.py index da3da657c..bcb725970 100755 --- a/radio/util/build-firmware.py +++ b/radio/util/build-firmware.py @@ -194,7 +194,10 @@ def build_firmware(path): for opt, value in command_options.items(): cmd.append("-D%s=%s" % (opt, value)) if "OPENTX_VERSION_SUFFIX" in os.environ: - cmd.append('-DVERSION_SUFFIX="%s"' % os.environ["OPENTX_VERSION_SUFFIX"]) + suffix = os.environ["OPENTX_VERSION_SUFFIX"] + cmd.append('-DVERSION_SUFFIX="%s"' % suffix) + if suffix.startswith("N"): + cmd.append('-DNIGHTLY_BUILD_WARNING') cmd.append(srcdir) proc = subprocess.Popen(cmd, stdout=subprocess.PIPE, stderr=subprocess.PIPE) output, error = proc.communicate()