Run external tool in same shell as rails server

Answered

Hi All,

I have an external tool set to run a script before the rails server starts. This script does a few things but one key element is setting variables. It seems that external tools run in a separate shell to the rails server, as variables I set are not picked up by the rails server.

Is there a way to have the external tool execute before rails but in the same shell ?

3 comments
Comment actions Permalink

Hello,

that seems to be similar to the following issue, could you please take a look:

https://youtrack.jetbrains.com/issue/IDEA-179158

0
Comment actions Permalink

Hey, it's slightly different. The script I execute via external tools will set some shell variables, I'd like those to still be set when the shell opens to run the rails server. The rails server needs those variables to startup correctly, db backends etc. If I could somehow chain the steps to both run in the same shell one after the other that would solve the issue.

0
Comment actions Permalink

Unfortunately that kind of scenario isn't supported at the moment, but you can submit it on our platform tracker (https://youtrack.jetbrains.com/issues/IDEA). Have you tried also setting necessary environment variables in the Rails run configuration?

0

Please sign in to leave a comment.