mirror of
https://github.com/platformio/platformio-core.git
synced 2025-07-30 18:17:13 +02:00
Fix issue with quotes in CPPDEFINES when dumping data for IDE
This commit is contained in:
@ -10,7 +10,6 @@ board = uno
|
|||||||
platform = espressif
|
platform = espressif
|
||||||
framework = arduino
|
framework = arduino
|
||||||
board = nodemcu
|
board = nodemcu
|
||||||
build_flags = -D LED_BUILTIN=BUILTIN_LED
|
|
||||||
|
|
||||||
[env:teensy31]
|
[env:teensy31]
|
||||||
platform = teensy
|
platform = teensy
|
||||||
|
@ -228,6 +228,7 @@ def DumpIDEData(env):
|
|||||||
# https://github.com/platformio/platformio-atom-ide/issues/34
|
# https://github.com/platformio/platformio-atom-ide/issues/34
|
||||||
_new_defines = []
|
_new_defines = []
|
||||||
for item in env_.get("CPPDEFINES", []):
|
for item in env_.get("CPPDEFINES", []):
|
||||||
|
item = item.replace('\\"', '"')
|
||||||
if " " in item:
|
if " " in item:
|
||||||
_new_defines.append(item.replace(" ", "\\\\ "))
|
_new_defines.append(item.replace(" ", "\\\\ "))
|
||||||
else:
|
else:
|
||||||
|
@ -1,7 +1,7 @@
|
|||||||
{
|
{
|
||||||
"execPath": "{{ cxx_path.replace("\\", "/") }}",
|
"execPath": "{{ cxx_path.replace("\\", "/") }}",
|
||||||
"gccDefaultCFlags": "-fsyntax-only {{! cc_flags.replace(' -MMD ', ' ').replace('"', '\"') }}",
|
"gccDefaultCFlags": "-fsyntax-only {{! cc_flags.replace(' -MMD ', ' ').replace('"', '\\"') }}",
|
||||||
"gccDefaultCppFlags": "-fsyntax-only {{! cxx_flags.replace(' -MMD ', ' ').replace('"', '\"') }}",
|
"gccDefaultCppFlags": "-fsyntax-only {{! cxx_flags.replace(' -MMD ', ' ').replace('"', '\\"') }}",
|
||||||
"gccErrorLimit": 15,
|
"gccErrorLimit": 15,
|
||||||
"gccIncludePaths": "{{ ','.join(includes).replace("\\", "/") }}",
|
"gccIncludePaths": "{{ ','.join(includes).replace("\\", "/") }}",
|
||||||
"gccSuppressWarnings": false
|
"gccSuppressWarnings": false
|
||||||
|
Reference in New Issue
Block a user