Improve deployment script
This commit is contained in:
@@ -1,15 +1,23 @@
|
||||
#!/bin/bash
|
||||
|
||||
CURRENT_VERSION="1.1.1"
|
||||
VERSION_FILE="/Users/OKoester/Documents/Arduino/Marlin-2-0-x-Anycubic-i3-MEGA-S-Master/Marlin/src/inc/Version.h"
|
||||
FIRMWARE_FOLDER="/Users/OKoester/Documents/Arduino/Marlin-2-0-x-Anycubic-i3-MEGA-S-Master/.pio/build/"
|
||||
OUTPUT_FOLDER="/Users/OKoester/Desktop/i3_FIRMWARE"
|
||||
|
||||
mkdir $OUTPUT_FOLDER
|
||||
if [ -d "$OUTPUT_FOLDER" ]; then
|
||||
echo "$OUTPUT_FOLDER already exists."
|
||||
else
|
||||
mkdir $OUTPUT_FOLDER
|
||||
fi
|
||||
|
||||
CUSTOM_BUILD_VERSION=$(egrep -o "([0-9]{1,}\.)+[0-9]{1,}" $VERSION_FILE -m2 | tail -n1)
|
||||
|
||||
echo "Knutwurst's Mega Firmware Version: $CUSTOM_BUILD_VERSION"
|
||||
|
||||
cd $FIRMWARE_FOLDER
|
||||
for dir in $FIRMWARE_FOLDER/*/ # list directories in the form "/tmp/dirname/"
|
||||
for dir in $FIRMWARE_FOLDER/*/
|
||||
do
|
||||
dir=${dir%*/} # remove the trailing "/"
|
||||
echo ${dir##*/} # print everything after the final "<--/"
|
||||
cp ${dir##*/}/firmware.hex /$OUTPUT_FOLDER/${dir##*/}_v$CURRENT_VERSION.hex
|
||||
dir=${dir%*/}
|
||||
echo ${dir##*/}
|
||||
cp ${dir##*/}/firmware.hex /$OUTPUT_FOLDER/${dir##*/}_v$CUSTOM_BUILD_VERSION.hex
|
||||
done
|
@@ -14,7 +14,6 @@ board_build.f_cpu = 16000000L
|
||||
lib_deps = ${common.lib_deps}
|
||||
TMC26XStepper=https://github.com/trinamic/TMC26XStepper/archive/master.zip
|
||||
src_filter = ${common.default_src_filter} +<src/HAL/AVR>
|
||||
#extra_scripts = pre:build_i3_mega.py
|
||||
build_flags = ${common.build_flags} -DMOTHERBOARD=BOARD_TRIGORILLA_14 -DKNUTWURST_MEGA
|
||||
build_unflags = -DKNUTWURST_MEGA_S -DKNUTWURST_MEGA_X -DKNUTWURST_DGUS2_TFT -DKNUTWURST_TMC -DKNUTWURST_BLTOUCH
|
||||
|
||||
@@ -27,7 +26,6 @@ board_build.f_cpu = 16000000L
|
||||
lib_deps = ${common.lib_deps}
|
||||
TMC26XStepper=https://github.com/trinamic/TMC26XStepper/archive/master.zip
|
||||
src_filter = ${common.default_src_filter} +<src/HAL/AVR>
|
||||
#extra_scripts = pre:build_i3_mega_tmc.py
|
||||
build_flags = ${common.build_flags} -DMOTHERBOARD=BOARD_TRIGORILLA_14 -DKNUTWURST_MEGA -DKNUTWURST_TMC
|
||||
build_unflags = -DKNUTWURST_MEGA_S -DKNUTWURST_MEGA_X -DKNUTWURST_DGUS2_TFT -DKNUTWURST_BLTOUCH
|
||||
|
||||
@@ -42,7 +40,6 @@ board_build.f_cpu = 16000000L
|
||||
lib_deps = ${common.lib_deps}
|
||||
TMC26XStepper=https://github.com/trinamic/TMC26XStepper/archive/master.zip
|
||||
src_filter = ${common.default_src_filter} +<src/HAL/AVR>
|
||||
#extra_scripts = pre:build_i3_mega_s.py
|
||||
build_flags = ${common.build_flags} -DMOTHERBOARD=BOARD_TRIGORILLA_14 -DKNUTWURST_MEGA_S
|
||||
build_unflags = -DKNUTWURST_MEGA -DKNUTWURST_MEGA_X -DKNUTWURST_DGUS2_TFT -DKNUTWURST_TMC -DKNUTWURST_BLTOUCH
|
||||
|
||||
@@ -55,7 +52,6 @@ board_build.f_cpu = 16000000L
|
||||
lib_deps = ${common.lib_deps}
|
||||
TMC26XStepper=https://github.com/trinamic/TMC26XStepper/archive/master.zip
|
||||
src_filter = ${common.default_src_filter} +<src/HAL/AVR>
|
||||
#extra_scripts = pre:build_i3_mega_s_dgus.py
|
||||
build_flags = ${common.build_flags} -DMOTHERBOARD=BOARD_TRIGORILLA_14 -DKNUTWURST_MEGA_S -DKNUTWURST_DGUS2_TFT
|
||||
build_unflags = -DKNUTWURST_MEGA -DKNUTWURST_MEGA_X -DKNUTWURST_TMC -DKNUTWURST_BLTOUCH
|
||||
|
||||
@@ -68,7 +64,6 @@ board_build.f_cpu = 16000000L
|
||||
lib_deps = ${common.lib_deps}
|
||||
TMC26XStepper=https://github.com/trinamic/TMC26XStepper/archive/master.zip
|
||||
src_filter = ${common.default_src_filter} +<src/HAL/AVR>
|
||||
#extra_scripts = pre:build_i3_mega_s_dgus_tmc.py
|
||||
build_flags = ${common.build_flags} -DMOTHERBOARD=BOARD_TRIGORILLA_14 -DKNUTWURST_MEGA_S -DKNUTWURST_DGUS2_TFT -DKNUTWURST_TMC
|
||||
build_unflags = -DKNUTWURST_MEGA -DKNUTWURST_MEGA_X -DKNUTWURST_BLTOUCH
|
||||
|
||||
@@ -81,7 +76,6 @@ board_build.f_cpu = 16000000L
|
||||
lib_deps = ${common.lib_deps}
|
||||
TMC26XStepper=https://github.com/trinamic/TMC26XStepper/archive/master.zip
|
||||
src_filter = ${common.default_src_filter} +<src/HAL/AVR>
|
||||
#extra_scripts = pre:build_i3_mega_s_tmc.py
|
||||
build_flags = ${common.build_flags} -DMOTHERBOARD=BOARD_TRIGORILLA_14 -DKNUTWURST_MEGA_S -DKNUTWURST_TMC
|
||||
build_unflags = -DKNUTWURST_MEGA -DKNUTWURST_MEGA_X -DKNUTWURST_DGUS2_TFT -DKNUTWURST_BLTOUCH
|
||||
|
||||
@@ -96,7 +90,6 @@ board_build.f_cpu = 16000000L
|
||||
lib_deps = ${common.lib_deps}
|
||||
TMC26XStepper=https://github.com/trinamic/TMC26XStepper/archive/master.zip
|
||||
src_filter = ${common.default_src_filter} +<src/HAL/AVR>
|
||||
#extra_scripts = pre:build_i3_mega_s_tmc.py
|
||||
build_flags = ${common.build_flags} -DMOTHERBOARD=BOARD_TRIGORILLA_14 -DKNUTWURST_MEGA_X -DKNUTWURST_DGUS2_TFT
|
||||
build_unflags = -DKNUTWURST_MEGA -DKNUTWURST_MEGA_S -DKNUTWURST_TMC -DKNUTWURST_BLTOUCH
|
||||
|
||||
@@ -109,7 +102,6 @@ board_build.f_cpu = 16000000L
|
||||
lib_deps = ${common.lib_deps}
|
||||
TMC26XStepper=https://github.com/trinamic/TMC26XStepper/archive/master.zip
|
||||
src_filter = ${common.default_src_filter} +<src/HAL/AVR>
|
||||
#extra_scripts = pre:build_i3_mega_s_tmc.py
|
||||
build_flags = ${common.build_flags} -DMOTHERBOARD=BOARD_TRIGORILLA_14 -DKNUTWURST_MEGA_X -DKNUTWURST_DGUS2_TFT -DKNUTWURST_TMC
|
||||
build_unflags = -DKNUTWURST_MEGA -DKNUTWURST_MEGA_S -DKNUTWURST_BLTOUCH
|
||||
|
||||
@@ -129,7 +121,6 @@ board_build.f_cpu = 16000000L
|
||||
lib_deps = ${common.lib_deps}
|
||||
TMC26XStepper=https://github.com/trinamic/TMC26XStepper/archive/master.zip
|
||||
src_filter = ${common.default_src_filter} +<src/HAL/AVR>
|
||||
#extra_scripts = pre:build_i3_mega.py
|
||||
build_flags = ${common.build_flags} -DMOTHERBOARD=BOARD_TRIGORILLA_14 -DKNUTWURST_MEGA -DKNUTWURST_BLTOUCH
|
||||
build_unflags = -DKNUTWURST_MEGA_S -DKNUTWURST_MEGA_X -DKNUTWURST_DGUS2_TFT -DKNUTWURST_TMC
|
||||
|
||||
@@ -141,7 +132,6 @@ board_build.f_cpu = 16000000L
|
||||
lib_deps = ${common.lib_deps}
|
||||
TMC26XStepper=https://github.com/trinamic/TMC26XStepper/archive/master.zip
|
||||
src_filter = ${common.default_src_filter} +<src/HAL/AVR>
|
||||
#extra_scripts = pre:build_i3_mega_tmc.py
|
||||
build_flags = ${common.build_flags} -DMOTHERBOARD=BOARD_TRIGORILLA_14 -DKNUTWURST_MEGA -DKNUTWURST_TMC -DKNUTWURST_BLTOUCH
|
||||
build_unflags = -DKNUTWURST_MEGA_S -DKNUTWURST_MEGA_X -DKNUTWURST_DGUS2_TFT
|
||||
|
||||
@@ -153,7 +143,6 @@ board_build.f_cpu = 16000000L
|
||||
lib_deps = ${common.lib_deps}
|
||||
TMC26XStepper=https://github.com/trinamic/TMC26XStepper/archive/master.zip
|
||||
src_filter = ${common.default_src_filter} +<src/HAL/AVR>
|
||||
#extra_scripts = pre:build_i3_mega_s.py
|
||||
build_flags = ${common.build_flags} -DMOTHERBOARD=BOARD_TRIGORILLA_14 -DKNUTWURST_MEGA_S -DKNUTWURST_BLTOUCH
|
||||
build_unflags = -DKNUTWURST_MEGA -DKNUTWURST_MEGA_X -DKNUTWURST_DGUS2_TFT -DKNUTWURST_TMC
|
||||
|
||||
@@ -166,7 +155,6 @@ board_build.f_cpu = 16000000L
|
||||
lib_deps = ${common.lib_deps}
|
||||
TMC26XStepper=https://github.com/trinamic/TMC26XStepper/archive/master.zip
|
||||
src_filter = ${common.default_src_filter} +<src/HAL/AVR>
|
||||
#extra_scripts = pre:build_i3_mega_s_dgus.py
|
||||
build_flags = ${common.build_flags} -DMOTHERBOARD=BOARD_TRIGORILLA_14 -DKNUTWURST_MEGA_S -DKNUTWURST_DGUS2_TFT -DKNUTWURST_BLTOUCH
|
||||
build_unflags = -DKNUTWURST_MEGA -DKNUTWURST_MEGA_X -DKNUTWURST_TMC
|
||||
|
||||
@@ -179,7 +167,6 @@ board_build.f_cpu = 16000000L
|
||||
lib_deps = ${common.lib_deps}
|
||||
TMC26XStepper=https://github.com/trinamic/TMC26XStepper/archive/master.zip
|
||||
src_filter = ${common.default_src_filter} +<src/HAL/AVR>
|
||||
#extra_scripts = pre:build_i3_mega_s_dgus_tmc.py
|
||||
build_flags = ${common.build_flags} -DMOTHERBOARD=BOARD_TRIGORILLA_14 -DKNUTWURST_MEGA_S -DKNUTWURST_DGUS2_TFT -DKNUTWURST_TMC -DKNUTWURST_BLTOUCH
|
||||
build_unflags = -DKNUTWURST_MEGA -DKNUTWURST_MEGA_X
|
||||
|
||||
@@ -192,7 +179,6 @@ board_build.f_cpu = 16000000L
|
||||
lib_deps = ${common.lib_deps}
|
||||
TMC26XStepper=https://github.com/trinamic/TMC26XStepper/archive/master.zip
|
||||
src_filter = ${common.default_src_filter} +<src/HAL/AVR>
|
||||
#extra_scripts = pre:build_i3_mega_s_tmc.py
|
||||
build_flags = ${common.build_flags} -DMOTHERBOARD=BOARD_TRIGORILLA_14 -DKNUTWURST_MEGA_S -DKNUTWURST_TMC -DKNUTWURST_BLTOUCH
|
||||
build_unflags = -DKNUTWURST_MEGA -DKNUTWURST_MEGA_X -DKNUTWURST_DGUS2_TFT
|
||||
|
||||
@@ -204,7 +190,6 @@ board_build.f_cpu = 16000000L
|
||||
lib_deps = ${common.lib_deps}
|
||||
TMC26XStepper=https://github.com/trinamic/TMC26XStepper/archive/master.zip
|
||||
src_filter = ${common.default_src_filter} +<src/HAL/AVR>
|
||||
#extra_scripts = pre:build_i3_mega_s_tmc.py
|
||||
build_flags = ${common.build_flags} -DMOTHERBOARD=BOARD_TRIGORILLA_14 -DKNUTWURST_MEGA_X -DKNUTWURST_DGUS2_TFT -DKNUTWURST_BLTOUCH
|
||||
build_unflags = -DKNUTWURST_MEGA -DKNUTWURST_MEGA_S -DKNUTWURST_TMC
|
||||
|
||||
@@ -217,7 +202,6 @@ board_build.f_cpu = 16000000L
|
||||
lib_deps = ${common.lib_deps}
|
||||
TMC26XStepper=https://github.com/trinamic/TMC26XStepper/archive/master.zip
|
||||
src_filter = ${common.default_src_filter} +<src/HAL/AVR>
|
||||
#extra_scripts = pre:build_i3_mega_s_tmc.py
|
||||
build_flags = ${common.build_flags} -DMOTHERBOARD=BOARD_TRIGORILLA_14 -DKNUTWURST_MEGA_X -DKNUTWURST_DGUS2_TFT -DKNUTWURST_TMC -DKNUTWURST_BLTOUCH
|
||||
build_unflags = -DKNUTWURST_MEGA -DKNUTWURST_MEGA_S
|
||||
|
||||
@@ -234,7 +218,6 @@ board_build.f_cpu = 16000000L
|
||||
lib_deps = ${common.lib_deps}
|
||||
TMC26XStepper=https://github.com/trinamic/TMC26XStepper/archive/master.zip
|
||||
src_filter = ${common.default_src_filter} +<src/HAL/AVR>
|
||||
#extra_scripts = pre:build_i3_mega.py
|
||||
build_flags = ${common.build_flags} -DMOTHERBOARD=BOARD_TRIGORILLA_14_11 -DKNUTWURST_MEGA -DKNUTWURST_BLTOUCH
|
||||
build_unflags = -DKNUTWURST_MEGA_S -DKNUTWURST_MEGA_X -DKNUTWURST_DGUS2_TFT -DKNUTWURST_TMC
|
||||
|
||||
@@ -246,7 +229,6 @@ board_build.f_cpu = 16000000L
|
||||
lib_deps = ${common.lib_deps}
|
||||
TMC26XStepper=https://github.com/trinamic/TMC26XStepper/archive/master.zip
|
||||
src_filter = ${common.default_src_filter} +<src/HAL/AVR>
|
||||
#extra_scripts = pre:build_i3_mega_tmc.py
|
||||
build_flags = ${common.build_flags} -DMOTHERBOARD=BOARD_TRIGORILLA_14_11 -DKNUTWURST_MEGA -DKNUTWURST_TMC -DKNUTWURST_BLTOUCH
|
||||
build_unflags = -DKNUTWURST_MEGA_S -DKNUTWURST_MEGA_X -DKNUTWURST_DGUS2_TFT
|
||||
|
||||
@@ -258,7 +240,6 @@ board_build.f_cpu = 16000000L
|
||||
lib_deps = ${common.lib_deps}
|
||||
TMC26XStepper=https://github.com/trinamic/TMC26XStepper/archive/master.zip
|
||||
src_filter = ${common.default_src_filter} +<src/HAL/AVR>
|
||||
#extra_scripts = pre:build_i3_mega_s.py
|
||||
build_flags = ${common.build_flags} -DMOTHERBOARD=BOARD_TRIGORILLA_14_11 -DKNUTWURST_MEGA_S -DKNUTWURST_BLTOUCH
|
||||
build_unflags = -DKNUTWURST_MEGA -DKNUTWURST_MEGA_X -DKNUTWURST_DGUS2_TFT -DKNUTWURST_TMC
|
||||
|
||||
@@ -271,7 +252,6 @@ board_build.f_cpu = 16000000L
|
||||
lib_deps = ${common.lib_deps}
|
||||
TMC26XStepper=https://github.com/trinamic/TMC26XStepper/archive/master.zip
|
||||
src_filter = ${common.default_src_filter} +<src/HAL/AVR>
|
||||
#extra_scripts = pre:build_i3_mega_s_dgus.py
|
||||
build_flags = ${common.build_flags} -DMOTHERBOARD=BOARD_TRIGORILLA_14_11 -DKNUTWURST_MEGA_S -DKNUTWURST_DGUS2_TFT -DKNUTWURST_BLTOUCH
|
||||
build_unflags = -DKNUTWURST_MEGA -DKNUTWURST_MEGA_X -DKNUTWURST_TMC
|
||||
|
||||
@@ -284,7 +264,6 @@ board_build.f_cpu = 16000000L
|
||||
lib_deps = ${common.lib_deps}
|
||||
TMC26XStepper=https://github.com/trinamic/TMC26XStepper/archive/master.zip
|
||||
src_filter = ${common.default_src_filter} +<src/HAL/AVR>
|
||||
#extra_scripts = pre:build_i3_mega_s_dgus_tmc.py
|
||||
build_flags = ${common.build_flags} -DMOTHERBOARD=BOARD_TRIGORILLA_14_11 -DKNUTWURST_MEGA_S -DKNUTWURST_DGUS2_TFT -DKNUTWURST_TMC -DKNUTWURST_BLTOUCH
|
||||
build_unflags = -DKNUTWURST_MEGA -DKNUTWURST_MEGA_X
|
||||
|
||||
@@ -297,7 +276,6 @@ board_build.f_cpu = 16000000L
|
||||
lib_deps = ${common.lib_deps}
|
||||
TMC26XStepper=https://github.com/trinamic/TMC26XStepper/archive/master.zip
|
||||
src_filter = ${common.default_src_filter} +<src/HAL/AVR>
|
||||
#extra_scripts = pre:build_i3_mega_s_tmc.py
|
||||
build_flags = ${common.build_flags} -DMOTHERBOARD=BOARD_TRIGORILLA_14_11 -DKNUTWURST_MEGA_S -DKNUTWURST_TMC -DKNUTWURST_BLTOUCH
|
||||
build_unflags = -DKNUTWURST_MEGA -DKNUTWURST_MEGA_X -DKNUTWURST_DGUS2_TFT
|
||||
|
||||
@@ -309,7 +287,6 @@ board_build.f_cpu = 16000000L
|
||||
lib_deps = ${common.lib_deps}
|
||||
TMC26XStepper=https://github.com/trinamic/TMC26XStepper/archive/master.zip
|
||||
src_filter = ${common.default_src_filter} +<src/HAL/AVR>
|
||||
#extra_scripts = pre:build_i3_mega_s_tmc.py
|
||||
build_flags = ${common.build_flags} -DMOTHERBOARD=BOARD_TRIGORILLA_14_11 -DKNUTWURST_MEGA_X -DKNUTWURST_DGUS2_TFT -DKNUTWURST_BLTOUCH
|
||||
build_unflags = -DKNUTWURST_MEGA -DKNUTWURST_MEGA_S -DKNUTWURST_TMC
|
||||
|
||||
@@ -322,6 +299,5 @@ board_build.f_cpu = 16000000L
|
||||
lib_deps = ${common.lib_deps}
|
||||
TMC26XStepper=https://github.com/trinamic/TMC26XStepper/archive/master.zip
|
||||
src_filter = ${common.default_src_filter} +<src/HAL/AVR>
|
||||
#extra_scripts = pre:build_i3_mega_s_tmc.py
|
||||
build_flags = ${common.build_flags} -DMOTHERBOARD=BOARD_TRIGORILLA_14_11 -DKNUTWURST_MEGA_X -DKNUTWURST_DGUS2_TFT -DKNUTWURST_TMC -DKNUTWURST_BLTOUCH
|
||||
build_unflags = -DKNUTWURST_MEGA -DKNUTWURST_MEGA_S
|
Reference in New Issue
Block a user