浏览代码

Better opt_set comment of old val

Scott Lahteine 3 年前
父节点
当前提交
6f494e9bed
共有 1 个文件被更改,包括 1 次插入1 次删除
  1. 1
    1
      buildroot/bin/opt_set

+ 1
- 1
buildroot/bin/opt_set 查看文件

@@ -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" ||

正在加载...
取消
保存