Skip to content

Commit 3b73338

Browse files
author
jan
committed
use same workaround for linux as windows
1 parent 1d7d427 commit 3b73338

File tree

1 file changed

+5
-9
lines changed

1 file changed

+5
-9
lines changed

io.sloeber.core/src/io/sloeber/core/txt/WorkAround.java

+5-9
Original file line numberDiff line numberDiff line change
@@ -45,7 +45,7 @@
4545
public class WorkAround {
4646
// Each time this class is touched consider changing the String below to enforce
4747
// updates
48-
private static final String FIRST_SLOEBER_WORKAROUND_LINE = "#Sloeber created TXT file V3.00.test 22 ";
48+
private static final String FIRST_SLOEBER_WORKAROUND_LINE = "#Sloeber created TXT file V3.00.test 23 ";
4949

5050
private static Map<String, String> USB_replacers;
5151

@@ -169,10 +169,8 @@ public static String boardsApplyWorkArounds(String inBoardsTXT) {
169169
boardsTXT = boardsTXT.replaceAll(" ['\\\"]?(-DMBEDTLS_\\S+)=\\\\?\"(mbedtls\\S+?)\\\\?\\\"[\"']? ",
170170
" \\\"$1=\\\\\\\"$2\\\\\\\"\\\" ");
171171

172-
if (isWindows) {
173-
for(Entry<String, String> curEntry:USB_replacers.entrySet()) {
174-
boardsTXT = boardsTXT.replace(curEntry.getKey(), curEntry.getValue());
175-
}
172+
for (Entry<String, String> curEntry : USB_replacers.entrySet()) {
173+
boardsTXT = boardsTXT.replace(curEntry.getKey(), curEntry.getValue());
176174
}
177175
boardsTXT = boardsTXT.replace("{", "${");
178176
return boardsTXT;
@@ -476,10 +474,8 @@ private static String platformApplyStandardWorkArounds(String inPlatformTxt) {
476474
// "-DUSB_PRODUCT=\"{build.usb_product}\""
477475
// platformTXT = platformTXT.replaceAll("\\'-D(\\S+)=\\{(\\S+)}\\'",
478476
// "\"-D$1=\\\\\"{$2}\\\\\"\"");
479-
if (isWindows) {
480-
for(Entry<String, String> curEntry:USB_replacers.entrySet()) {
481-
platformTXT = platformTXT.replace(curEntry.getKey(), curEntry.getValue());
482-
}
477+
for (Entry<String, String> curEntry : USB_replacers.entrySet()) {
478+
platformTXT = platformTXT.replace(curEntry.getKey(), curEntry.getValue());
483479
}
484480

485481
// quoting fixes for embedutils

0 commit comments

Comments
 (0)