|
@@ -8,7 +8,7 @@ SED=$(which gsed || which sed)
|
8
|
8
|
while [[ $# > 1 ]]; do
|
9
|
9
|
DID=0
|
10
|
10
|
for FN in Configuration Configuration_adv; do
|
11
|
|
- "${SED}" -i "/^\(\s*\)\/*\s*\(#define\s\+${1}\b\)\(.*\)$/{s//\1\2 ${2} \/\/ \3/;h};\${x;/./{x;q0};x;q9}" Marlin/$FN.h && DID=1
|
|
11
|
+ "${SED}" -i "/^\(\s*\)\/*\s*\(#define\s\+${1}\b\) *\(.*\)$/{s//\1\2 ${2} \/\/ \3/;h};\${x;/./{x;q0};x;q9}" Marlin/$FN.h && DID=1
|
12
|
12
|
done
|
13
|
13
|
((DID)) ||
|
14
|
14
|
eval "echo '#define ${1} ${2}' >>Marlin/Configuration.h" ||
|