-
-
Notifications
You must be signed in to change notification settings - Fork 789
-
-
Notifications
You must be signed in to change notification settings - Fork 789
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Feature request : Better integration of environments in CLion #2824
Comments
Started a CLion Plugin at github.com/nexoscp/PlatformIOLion. Help is welcome! |
@nexoscp wow!!! Do you need any help from our side? |
@Teo-CD Great work on https://github.com/platformio/platformio-core/compare/develop...Teo-CD:clion-integration?expand=1 I've just refactored a little bit ProjectGenerator (see 1dc1532) and added So, you have full access to ProjectConfig via Could you remove your branch and create a new one based on |
Help is always welcome. I'm new to PlatformIO so having a feature list to catch up withe the other IDEs would be great. |
I think the first what should be implemented is PlatofrmIO Core installer. We wrote it in JS and some part of it is ported to Java by @gholdys https://github.com/platformio/platformio-eclipse-ide/tree/master/src/com/insightmachines/pio/installer The original source code is located here https://github.com/platformio/platformio-node-helpers/tree/master/src/installer What does this installer do? It creates a Python virtual environment using different methods and installs PIO Core. So, it means that no need to ask a user to install PIO Core manually. When user starts Eclipse/CLIon, the extension checks PIO Core installation and does everything automatically. They, the extension uses it for PIO Core calls. The questionSorry, I'm not Java developer. Is it possible to have something similar to Thanks! |
And i'm not firm with python, but that should not stop us. Will look into it the next days. For now i have to pack my stuff for CCCamp. If someone want to meet and chat ping me on @nexoscp |
You don't need to know Python :) We use PlatformIO from IDE via CLI. Reading JavaScript code could help to make this |
Had a look at platformio-eclipse-ide. Thx @gholdys ! I see two tasks here:
|
addad a Gradle-Build to publish a JAR: PR |
I'm glad someone will take-over the development of this plugin. @nexoscp, feel free to change the package name. I used my default one, but it probably should be something more PlatformIO oriented. |
I have some draft plugin code with a view that contains a browser. I've managed to successfully open the home page of a local PlatformIO build server in this browser. I'll commit it by the end of this week. |
is there already a established package name for PlatformIO on JVM? If not, is |
That would be the most proper package name (at least according to the convention for Java packages) |
Good idea! +1 |
Thank you @ivankravets ! I really like the changes you made to ProjectGenerator, I'll create a branch based on Really nice to see the start of a CLion plugin ! I hope you will succeed with this endeavour, a CLion plugin would be awesome to have! 😃 @nexoscp |
@Teo-CD great work! I like the new integration! PIO Core 4.0.3 is coming today 😊 |
@nexoscp could you contact me@ikravets.com? I would like to discuss what can we do with better integration with CLIon. |
Thank you @ivankravets , I am happy that it worked out nicely ! Really glad to have contributed :D This experience has cemented my wish to contribute more to open source projects - and to platformio if the occasion arises! Should I update CLion's page on the documentation to document the new integration ? |
Could you upgrade PIO Core to 4.0.3rc via |
Going to do that right now. My guess would be to quote env names in a way that CMakes does not leave out the space. I'm going to look into it |
@ivankravets Everything works as expected apart from when the env names has a space in it as you mentioned.
{{ env }} to "{{ env }}" in
Tested the modification with two envs sharing the same first word ( |
Thanks! It worked! |
@ivankravets Re-tested project generation for CLion from an empty project, it mainly completes but produces an error message as platformio-core/platformio/ide/tpls/clion/CMakeListsPrivate.txt.tpl Lines 62 to 64 in db6f983
I don't know the cleanest way to handle this but adding an |
Thanks, fixed! |
@ivankravets Sorry to be slow to find the bugs, but there is another one: when there are exactly two environments, Python throws the error
when called from
This one I do not know how to fix. |
4.0.3 is out https://github.com/platformio/platformio-core/releases/tag/v4.0.3 and the last bug is fixed in 4.0.4a1. If this is a critical issue, we will release 4.0.4 next week. |
Existing projects with 2 environments should be fine, but not benefit from the new integration. You cannot init at all from scratch with 2 environments though. Everything else is behaving as expected (This time, tested it all x) ). I do not know how many people would be affected, but I suppose not that many ? |
Updated CLion image
Updated CLion image
Updated CLion image
Hi. I love platformio and have been using it for two years with CLion without a hitch. Recently I have started using multiple environments but they do not integrate at all in CLion :
Those issues forced me to add a dummy environment, write some custom CMake and have some manual setup after each
pio init
, even though I felt that this could be integrated in platformio.In the process of solving this issues for my project, I found ways around them which seemed very portable and thought that they might help enhance platformio's integration with CLion.
I forked the repo, tried some things around and I managed to solve the above-mentioned issues. Should I submit a PR ?
The text was updated successfully, but these errors were encountered: