I would argue there is little difference between SDK 1.5 and SDK 2.x - The issue is in how you are using the SDK within VS Code.So, there is a way to archive a project without the build directory but you need to know the secret of importing instead of opening in order to recreate the project. This is very different behavior from version 1.5.
If you choose to install and use the official Raspberry Pi VS Code Pico Extension, for good or bad, you are then tied into that, you need to play by its rules, you have to jump through the hoops it requires you to jump through.
But, if you don't install that, just upgrade the SDK from 1.5 to 2.x, things should keep working the same way as they always did.
For example, I have SDK 2.1 installed. I also have a directory with just two files in it, 'CMakeLists.txt' and 'main.c' - effectively an archived project reinstated on disk. In VS Code I can click 'File', 'Open Folder', select that directory, and it will auto-run 'cmake', create the './build' directory and required files within that. I can then click 'build' in the toolbar and it does.
Nothing with respect to VS Code, moving from SDK 1.5 to 2.x, has changed. What has changed is that you are choosing to use the official Raspberry Pi VS Code Pico Extension when you presumably weren't using that before.
Statistics: Posted by hippy — Sun Dec 29, 2024 5:48 pm