Browse Source

🔨 Strip CR in mftest > awk

Scott Lahteine 2 years ago
parent
commit
c55b66bece
1 changed files with 1 additions and 1 deletions
  1. 1
    1
      buildroot/bin/mftest

+ 1
- 1
buildroot/bin/mftest View File

@@ -150,7 +150,7 @@ if ((AUTO_BUILD)); then
150 150
          *) SYS='uni' ;;
151 151
   esac
152 152
   echo ; echo -n "Auto " ; ((AUTO_BUILD == 2)) && echo "Upload..." || echo "Build..."
153
-  MB=$( grep -E "^\s*#define MOTHERBOARD" Marlin/Configuration.h | awk '{ print $3 }' | $SED 's/BOARD_//' )
153
+  MB=$( grep -E "^\s*#define MOTHERBOARD" Marlin/Configuration.h | awk '{ print $3 }' | $SED 's/BOARD_//;s/\r//' )
154 154
   [[ -z $MB ]] && { echo "Error - Can't read MOTHERBOARD setting." ; exit 1 ; }
155 155
   BLINE=$( grep -E "define\s+BOARD_$MB\b" Marlin/src/core/boards.h )
156 156
   BNUM=$( $SED -E 's/^.+BOARD_[^ ]+ +([0-9]+).+$/\1/' <<<"$BLINE" )

Loading…
Cancel
Save