PlatformIO is great, CLion is great too! However, when they come together there is no use of them.
Code generation and refactoring does not work in CLion for PlatformIO. The only place where it partly(!) works is main.cpp and headers. Since that CLion is almost useless for PlatformIO.
Can anybody help me to solve this problem?
I like CLion for its ReSharper. For me, this is the only reason to use PlatformIO by now.
I’d like to move from VS2022 to CLion for Arduino Projects. And yet I had to stay with VS2022 and vMicro, unfortunately.
CLion only performs such actions in included files. The blue square in the icon of the file indicates that it is included. I assume that the only included file in your project is main.cpp, which is why refactoring only works there (not sure why it does work in headers).
In PlatformIO, the way to include your source code is by opening up the PlatformIO sidebar and clicking the “Reload PlaformIO Project”.