EMbitz
Quotes in variable expansion - Printable Version

+- EMbitz (https://www.embitz.org/forum)
+-- Forum: EmBitz (https://www.embitz.org/forum/forum-1.html)
+--- Forum: Bug report (https://www.embitz.org/forum/forum-8.html)
+--- Thread: Quotes in variable expansion (/thread-14.html)



Quotes in variable expansion - Mink - 15-09-2020

EmBitz supports variable expansion such as the ${PROJECT_DIR}, ${TARGET_OUTPUT_DIR} and others.
If there is a space in the path, quotes are added and this is a very bad idea!
For example, let the project be in the folder

Code:
С:\MyProjects\STM32\Test Blink\

If you use variable expansion in the tool (e.g. flashing a hex file using EBlink).
This will mess up the command line which will be like this

Code:
"С:\MyProjects\STM32\Test Blink\"bin\Release\"Test Blink".hex

It is necessary that the quotes are not automatically added if there are spaces in the path. Then this tool will work fine.

Code:
-I stlink,swd -S stm32-auto -F file="${PROJECT_DIR}${TARGET_OUTPUT_DIR}${TARGET_OUTPUT_BASENAME}.hex"

Now this is not possible if there are spaces in the file path.


RE: Quotes in variable expansion - embitz - 17-09-2020

hmmm, I see.

If it doesn't give any backward compatibility problems then I will remove them


RE: Quotes in variable expansion - embitz - 22-09-2020

Ok, I have the same problem with my context menu handler if the file is in a spaced folder name.
I will solve this for the EBlink win32 version.

[attachment=10]


RE: Quotes in variable expansion - embitz - 22-09-2020

Alright, version 3.0 supports spaces in folder names


RE: Quotes in variable expansion - embitz - 22-09-2020

Here 3.0 pre-release.


RE: Quotes in variable expansion - Mink - 23-09-2020

Error with quotes in EmBitz.
So I created a project named 12 34 located in the folder D:\STM32\
EmBitz added quotes in variable expansion and because of this the command line is "broken".