From 3ff9dc0fa9f340df977424f1fcaf938e903e20c6 Mon Sep 17 00:00:00 2001 From: Knutwurst <36196269+knutwurst@users.noreply.github.com> Date: Sun, 4 Oct 2020 12:51:02 +0200 Subject: [PATCH] Include beta version handling in deploy script --- .github/workflows/build-all.yml | 4 ++-- Marlin/src/inc/Version.h | 2 +- deploy_firmware_files.sh | 2 +- 3 files changed, 4 insertions(+), 4 deletions(-) diff --git a/.github/workflows/build-all.yml b/.github/workflows/build-all.yml index 8730bcda..dd03e3ac 100755 --- a/.github/workflows/build-all.yml +++ b/.github/workflows/build-all.yml @@ -91,12 +91,12 @@ jobs: - name: Set Environment Variables run: | - CUSTOM_BUILD_VERSION=$(egrep -o "([0-9]{1,}\.)+[0-9]{1,}" Marlin/src/inc/Version.h -m2 | tail -n1) && \ + CUSTOM_BUILD_VERSION=$(egrep -o "([0-9]{1,}\.)+[a-zA-Z0-9_.-]{1,}" Marlin/src/inc/Version.h -m2 | tail -n1) && \ echo "::set-env name=CUSTOM_BUILD_VER::$CUSTOM_BUILD_VERSION" - name: Rename Output Files run: | - CUSTOM_BUILD_VERSION=$(egrep -o "([0-9]{1,}\.)+[0-9]{1,}" Marlin/src/inc/Version.h -m2 | tail -n1) && \ + CUSTOM_BUILD_VERSION=$(egrep -o "([0-9]{1,}\.)+[a-zA-Z0-9_.-]{1,}" Marlin/src/inc/Version.h -m2 | tail -n1) && \ mv .pio/build/${{ matrix.platform }}/firmware.hex .pio/build/${{ matrix.platform }}/${{ matrix.platform }}_v$CUSTOM_BUILD_VERSION.hex #- name: Archive artifacts into single Files diff --git a/Marlin/src/inc/Version.h b/Marlin/src/inc/Version.h index 7001c850..97416fe4 100755 --- a/Marlin/src/inc/Version.h +++ b/Marlin/src/inc/Version.h @@ -41,7 +41,7 @@ * here we define this default string as the date where the latest release * version was tagged. */ - #define CUSTOM_BUILD_VERSION "1.1.7_BETA" + #define CUSTOM_BUILD_VERSION "1.1.7-BETA1" #ifndef STRING_DISTRIBUTION_DATE #define STRING_DISTRIBUTION_DATE "2020-10-04" diff --git a/deploy_firmware_files.sh b/deploy_firmware_files.sh index e339d2f5..c2274304 100755 --- a/deploy_firmware_files.sh +++ b/deploy_firmware_files.sh @@ -4,7 +4,7 @@ VERSION_FILE="/Users/OKoester/Documents/Arduino/Marlin-2-0-x-Anycubic-i3-MEGA-S- FIRMWARE_FOLDER="/Users/OKoester/Documents/Arduino/Marlin-2-0-x-Anycubic-i3-MEGA-S-Master/.pio/build/" OUTPUT_FOLDER="/Users/OKoester/Desktop/i3_FIRMWARE" -CUSTOM_BUILD_VERSION=$(egrep -o "([0-9]{1,}\.)+[0-9]{1,}" $VERSION_FILE -m2 | tail -n1) +CUSTOM_BUILD_VERSION=$(egrep -o "([0-9]{1,}\.)+[a-zA-Z0-9_.-]{1,}" $VERSION_FILE -m2 | tail -n1) if [ -d "$$OUTPUT_FOLDER/v$CUSTOM_BUILD_VERSION" ]; then echo "$$OUTPUT_FOLDER/$CUSTOM_BUILD_VERSION already exists."