Skip to content
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

IDE generator only generates project file based on last env in existing platformio.ini file, ignoring --board #242

Closed
pastcompute opened this issue Jun 25, 2015 · 2 comments
Assignees
Labels
Milestone

Comments

@pastcompute
Copy link

When I run the following command as suggested by the tutorial:

platformio init --ide qtcreator --board esp01

and the platformio.ini file in the directory contains a second env:teensylc section after the env:esp01 section, the generator ignored the --board esp01 option and always generates a teensylc-based qtcreator project.

I had a browse through the code and noted in projectgenerator.py it scans through the ini file and populates a map in function get_project_env() and this seems to take no notice of the ide selection; for any number of env sections they will keep getting replaced (thus the choice of the last in the file)
I guess a fix would involve reworking how that method gets called, maybe a second loop in generate() over boards, but my head is not in Python mode at the moment

@pastcompute pastcompute changed the title IDE generator only builds project for last env in existing platformio.ini file IDE generator only generates project file based on last env in existing platformio.ini file, ignoring --board Jun 25, 2015
@ivankravets ivankravets added this to the 2.2.0 milestone Jun 25, 2015
@ivankravets ivankravets self-assigned this Jun 25, 2015
@ivankravets
Copy link
Member

Thanks, I'll fix it in 2.2.0 release.

@ivankravets
Copy link
Member

Please re-test it using development version.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

2 participants