I am using RubyMine IDE with RVM for Ruby version management and
bundler install --path vendor/bundle
to keep my gems local. However, RubyMine doesn't seem to be reading my .bundle/config file which specifies where my gems are located with the BUNDLE_PATH property:
BUNDLE_PATH: vendor/bundle
BUNDLE_DISABLE_SHARED_GEMS: '1'
I have found some sources which indicate that RubyMine should support this, but can't seem to find any explanation of exactly how it works or how to fix it properly.
This thread seems to indicate that RubyMine should pick up the bundler/config
"if you configured bundler to install gems in vendor/bundle by-default then RM is supposed to handle this (and if it is not then this is a bug)." http://devnet.jetbrains.com/thread/441239
Here's a few more RubyMine bugs indicating it is not working:
I also saw a stackoverflow thread, Using RVM Gemsets & Bundler & RubyMine, where someone complained about the same problem, but the solution was simply to install the gems under the RVM managed path by doing the following:
bundle install --system
Well, this defeats the purpose of keeping your gems isolated between projects. I know there are gemsets for this, but I much prefer not to use them.
The error I am seeing is the following when I try to run my project from RubyMine:
Error running Development: [No Rails found in SDK]
The other symptom is that my gems installed under vendor/bundle aren't visible under the "External Libraries" in the project view, only my Ruby SDK and bundler are installed here.
Also, this works and starts my server find from the command line: bundle exec rails server
But even when I try to run my server with "Run the script in the context of the bundle (bundle exec)", it still fails.
Actually running ruby mine from console through bundle helps!
$ bundle exec rubymine
Good luck!