lancaster-university / microbit-v2-samples

CODAL build tools and sample programs for the micro:bit v2.x
MIT License
64 stars 83 forks source link

build.py `--dev` flag does not do the same as codal.json `"dev": true` #86

Open microbit-carlos opened 3 months ago

microbit-carlos commented 3 months ago

Looking at build.py, the dev flag is described as "enable developer mode (does not use target-locked.json)":

https://github.com/lancaster-university/microbit-v2-samples/blob/1a3d47796b2869b2c473da5ae316450d2bedb29e/build.py#L46


There is also another way to "enable developer mode" by setting the "target.dev": true key in codal.json. This mode is processed in the CMake files and it read target-locked.json instead of target.json from codal-microbit-v2: https://github.com/lancaster-university/microbit-v2-samples/blob/1a3d47796b2869b2c473da5ae316450d2bedb29e/CMakeLists.txt#L67-L73

The build.py --dev flag it's only used:

With the normal python build.py invocation with the --dev flag does not do anything at all, which is also a bit confusing.