bmd-studio / stm32-for-vscode

STM32 extension for working with STM32 and CubeMX in VSCode
MIT License
207 stars 27 forks source link

Fix openocdPath Setting Comparison #169

Closed cvanbeek13 closed 9 months ago

cvanbeek13 commented 10 months ago

In my project, every time I opened VSCode, the cortex-debug.openocdPath variable was written to my settings.json or .code-workspace file, even though I had it set in my user settings.json file.

I believe this issue was fixed by changing this comparison. Previously, tools.openOCDPath was an object, and cortexDebugSetting.get('openocdPath') returned a string. This forces the types to be the same so that the actual settings are compared.

cvanbeek13 commented 10 months ago

I think this is related to #81

jortbmd commented 10 months ago

Hi! Thanks for looking into this and creating a pull request! This might very well be the issue. I have stared at that line several times thinking there was nothing wrong. Will verify it and if everything is good I will implement it as a hot fix.