RubyMine plugin: How to invoke a rake task for specified Rails-environment?
Hi!
There was similar discussion about invoking rake-tasks using RubyMine API: https://devnet.jetbrains.com/message/5446931#5446931 and provided method was successfully used for a long time. But now I'd like to invoke a rake task for specific Rails environment (dev, test, prod) from RubyMine plugin (basically, set RAILS_ENV environment variable before running the task). I'm not sure it's possible to set env. variables in GemsRunner.runGemsExecutableScript, so could you please advise?
Thank you,
Basil.
Please sign in to leave a comment.
Hi Basil,
Unfortunately there doesn't seem to be a good API to do what you need. You're welcome to file a YouTrack issue (in the RUBY project) asking for one to be added.
Just an update for this ooold issue :) While I managed to find some workaround for env vars before, now I cannot find any so some env vars api is required. The ticket is here: https://youtrack.jetbrains.com/issue/RUBY-17908.
Related GitHub issue - https://github.com/basgren/railways/issues/22.
RubyMine team, could you please take a look and tell whether this can be implemented?
Thank you very much!