How to set bundler for RubyMine 7.0.2?
Hi
I have RubyMine 7.0.2 installed on an Ubuntu 12.04 pc with bundler v 1.7.12. In the settings under Ruby SDK and Gems, the only ruy mentioned there is ruby-1.9.3-p0. There is a long list of gems in the window next to it.
There doesn't appear to be any errors in my ruby code (nothing shows up as red - there are warnings). When I press the run or debug buttons, in the Console I get rhe following:
Fast Debugger (ruby-debug-ide 0.4.24, ruby-debug-base19x 0.11.30.pre15) listens on 127.0.0.1:42094
Uncaught exception: Bundler could not find compatible versions for gem "bundler":
In Gemfile:
rails (= 4.0.0) depends on
bundler (< 2.0, >= 1.3.0)
Current Bundler version:
bundler (1.0.15)
I have a bundle under /usr/bin/X11 that is 1.0.15, so I'm thinking it is using that one, but when I ask which bundle in being used is say the 1.7.12 version:
$ which bundle
/usr/local/bin/bundle
$ /usr/local/bin/bundle -v
Bundler version 1.7.12
$
$ /usr/bin/X11/bundle -v
Bundler version 1.0.15
$
Here's some of the versions:
$ bundle -v
Bundler version 1.7.12
$
$ bundler -v
Bundler version 1.7.12
$
$ ruby -v
ruby 1.9.3p0 (2011-10-30 revision 33570) [x86_64-linux]
$
I'm not sure if this is helpful, but here is what I have for Ruby:
$ whereis ruby
ruby: /usr/bin/ruby /usr/bin/ruby1.8 /usr/lib/ruby /usr/bin/X11/ruby /usr/bin/X11/ruby1.8 /usr/share/man/man1/ruby.1.gz
$
$ which ruby
/usr/bin/ruby
$
I don't why it would use the /usr/bin/X11/bundle, or how to check that it is doing that in RubyMine, or if that is actually the problem? I do need RubyMine to start using the one in /usr/local/bin.
Any help would be greatly appreciated. Thanks...
ps: I haven't found a way to properly display code here, pointer to directions to that would be appreciated.
请先登录再写评论。
Hi,
could you please run the following command in terminal:
gem list bundler
and provide its output.
Regards, Oleg.
Hi Oleg,
Sure, here you go:
$ gem list bundler
*** LOCAL GEMS ***
bundler (1.7.12)
$
Thanks...
And what about Tools|Show Gem Environment in RubyMine?
Regards, Oleg.
Hi Oleg
It's a lot of stuff (the /home/mike/.gems directory doesn't exist):
RUBYGEMS VERSION: 1.8.11
RUBY VERSION: 1.9.3 (2011-10-30 patchlevel 0) [x86_64-linux]
INSTALLATION DIRECTORY: /var/lib/gems/1.9.1
RUBY EXECUTABLE: /usr/bin/ruby1.9.1
EXECUTABLE DIRECTORY: /usr/local/bin
RUBYGEMS PLATFORMS:
ruby
x86_64-linux
GEM PATHS:
/var/lib/gems/1.9.1
/home/mike/.gem/ruby/1.9.1
GEM CONFIGURATION:
:update_sources => true
:verbose => true
:benchmark => false
:backtrace => false
:bulk_threshold => 1000
REMOTE SOURCES:
http://rubygems.org/
----------------------
IDE: RubyMine 7.0.2, build #RM-139.800
OS: Linux 3.2.0-75-generic[amd64]
Java: 1.7.0_76-b13
RubyMine SDK Environment:
Sdk: ruby-1.9.3-p0
Sdk Version: ver.1.9.3p0 ( revision 33570) p0
Ruby Interpreter: /usr/bin/ruby
RVM Sdk: no
RVM Home: [n/a]
Sdk Language Level: 1.9
Sdk Load Path:
/usr/local/lib/site_ruby/1.9.1
/usr/local/lib/site_ruby/1.9.1/x86_64-linux
/usr/local/lib/site_ruby
/usr/lib/ruby/vendor_ruby
/usr/lib/ruby/1.9.1
/usr/lib/ruby/1.9.1/x86_64-linux
~/quarrio/RubyMine-7.0.2/rubystubs193
Sdk Gem paths:
/var/lib/gems/1.9.1/gems
~/.gem/ruby/1.9.1/gems
/var/lib/gems/1.9.1/bundler/gems
~/.gem/ruby/1.9.1/bundler/gems
Gems used:
net-http-persistent (2.9.4)
/var/lib/gems/1.9.1/gems/net-http-persistent-2.9.4
nokogiri (1.6.6.1)
~/.gem/ruby/1.9.1/gems/nokogiri-1.6.6.1
multipart-post (1.2.0)
/var/lib/gems/1.9.1/gems/multipart-post-1.2.0
railties (4.0.0)
/var/lib/gems/1.9.1/gems/railties-4.0.0
json (1.8.2)
~/.gem/ruby/1.9.1/gems/json-1.8.2
rails_12factor (0.0.3)
~/.gem/ruby/1.9.1/gems/rails_12factor-0.0.3
bundler (1.7.12)
/var/lib/gems/1.9.1/gems/bundler-1.7.12
rack-test (0.6.3)
~/.gem/ruby/1.9.1/gems/rack-test-0.6.3
rubyzip (1.0.0)
/var/lib/gems/1.9.1/gems/rubyzip-1.0.0
ansi (1.5.0)
~/.gem/ruby/1.9.1/gems/ansi-1.5.0
simplecov (0.9.1)
~/.gem/ruby/1.9.1/gems/simplecov-0.9.1
hashie (2.0.5)
/var/lib/gems/1.9.1/gems/hashie-2.0.5
pg (0.18.1)
~/.gem/ruby/1.9.1/gems/pg-0.18.1
faraday_middleware (0.9.1)
~/.gem/ruby/1.9.1/gems/faraday_middleware-0.9.1
axlsx (2.0.1)
/var/lib/gems/1.9.1/gems/axlsx-2.0.1
rake (10.4.2)
~/.gem/ruby/1.9.1/gems/rake-10.4.2
webrobots (0.1.1)
/var/lib/gems/1.9.1/gems/webrobots-0.1.1
ruby-prof (0.15.3)
~/.gem/ruby/1.9.1/gems/ruby-prof-0.15.3
jquery-ui-rails (5.0.3)
~/.gem/ruby/1.9.1/gems/jquery-ui-rails-5.0.3
faraday (0.8.9)
/var/lib/gems/1.9.1/gems/faraday-0.8.9
activerecord (4.0.0)
/var/lib/gems/1.9.1/gems/activerecord-4.0.0
thread_safe (0.3.4)
~/.gem/ruby/1.9.1/gems/thread_safe-0.3.4
diff-lcs (1.2.5)
~/.gem/ruby/1.9.1/gems/diff-lcs-1.2.5
activemodel (4.0.0)
/var/lib/gems/1.9.1/gems/activemodel-4.0.0
multi_xml (0.5.5)
~/.gem/ruby/1.9.1/gems/multi_xml-0.5.5
treetop (1.4.15)
/var/lib/gems/1.9.1/gems/treetop-1.4.15
twitter-bootstrap-rails (2.2.8)
/var/lib/gems/1.9.1/gems/twitter-bootstrap-rails-2.2.8
sprockets (2.12.3)
/var/lib/gems/1.9.1/gems/sprockets-2.12.3
rails (4.0.0)
/var/lib/gems/1.9.1/gems/rails-4.0.0
unf_ext (0.0.6)
/var/lib/gems/1.9.1/gems/unf_ext-0.0.6
actionmailer (4.0.0)
/var/lib/gems/1.9.1/gems/actionmailer-4.0.0
unf (0.1.4)
/var/lib/gems/1.9.1/gems/unf-0.1.4
mail (2.5.4)
/var/lib/gems/1.9.1/gems/mail-2.5.4
force (0.0.2)
~/.gem/ruby/1.9.1/gems/force-0.0.2
builder (3.1.4)
/var/lib/gems/1.9.1/gems/builder-3.1.4
tilt (1.4.1)
/var/lib/gems/1.9.1/gems/tilt-1.4.1
erubis (2.7.0)
/var/lib/gems/1.9.1/gems/erubis-2.7.0
mime-types (1.25.1)
/var/lib/gems/1.9.1/gems/mime-types-1.25.1
jwt (1.2.0)
~/.gem/ruby/1.9.1/gems/jwt-1.2.0
actionpack (4.0.0)
/var/lib/gems/1.9.1/gems/actionpack-4.0.0
http-cookie (1.0.2)
/var/lib/gems/1.9.1/gems/http-cookie-1.0.2
minitest-reporters (0.14.24)
/var/lib/gems/1.9.1/gems/minitest-reporters-0.14.24
polyglot (0.3.5)
~/.gem/ruby/1.9.1/gems/polyglot-0.3.5
chronic_duration (0.10.6)
~/.gem/ruby/1.9.1/gems/chronic_duration-0.10.6
execjs (2.2.2)
~/.gem/ruby/1.9.1/gems/execjs-2.2.2
chronic (0.10.2)
/var/lib/gems/1.9.1/gems/chronic-0.10.2
httplog (0.2.7)
/var/lib/gems/1.9.1/gems/httplog-0.2.7
minitest (4.7.5)
/var/lib/gems/1.9.1/gems/minitest-4.7.5
powerbar (1.0.12)
~/.gem/ruby/1.9.1/gems/powerbar-1.0.12
thor (0.19.1)
~/.gem/ruby/1.9.1/gems/thor-0.19.1
ntlm-http (0.1.1)
/var/lib/gems/1.9.1/gems/ntlm-http-0.1.1
oauth2 (1.0.0)
~/.gem/ruby/1.9.1/gems/oauth2-1.0.0
rails_stdout_logging (0.0.3)
/var/lib/gems/1.9.1/gems/rails_stdout_logging-0.0.3
docile (1.1.5)
~/.gem/ruby/1.9.1/gems/docile-1.1.5
rtf (0.3.3)
/var/lib/gems/1.9.1/gems/rtf-0.3.3
arel (4.0.2)
/var/lib/gems/1.9.1/gems/arel-4.0.2
rails_serve_static_assets (0.0.3)
~/.gem/ruby/1.9.1/gems/rails_serve_static_assets-0.0.3
net-http-digest_auth (1.4)
/var/lib/gems/1.9.1/gems/net-http-digest_auth-1.4
mini_portile (0.6.2)
~/.gem/ruby/1.9.1/gems/mini_portile-0.6.2
activerecord-deprecated_finders (1.0.3)
/var/lib/gems/1.9.1/gems/activerecord-deprecated_finders-1.0.3
jquery-rails (3.1.2)
/var/lib/gems/1.9.1/gems/jquery-rails-3.1.2
method_source (0.8.2)
/var/lib/gems/1.9.1/gems/method_source-0.8.2
omniauth-oauth2 (1.2.0)
~/.gem/ruby/1.9.1/gems/omniauth-oauth2-1.2.0
omniauth-salesforce ([path])
~/quarrio/metal/omniauth-salesforce-1.0.4
mechanize (2.7.2)
/var/lib/gems/1.9.1/gems/mechanize-2.7.2
eventmachine (1.0.4)
~/.gem/ruby/1.9.1/gems/eventmachine-1.0.4
hike (1.2.3)
/var/lib/gems/1.9.1/gems/hike-1.2.3
i18n (0.7.0)
~/.gem/ruby/1.9.1/gems/i18n-0.7.0
rack (1.5.2)
/var/lib/gems/1.9.1/gems/rack-1.5.2
multi_json (1.10.1)
~/.gem/ruby/1.9.1/gems/multi_json-1.10.1
rforce (0.12)
~/.gem/ruby/1.9.1/gems/rforce-0.12
orderedhash (0.0.6)
/var/lib/gems/1.9.1/gems/orderedhash-0.0.6
facets (3.0.0)
~/.gem/ruby/1.9.1/gems/facets-3.0.0
htmlentities (4.3.3)
~/.gem/ruby/1.9.1/gems/htmlentities-4.3.3
thin (1.6.3)
/var/lib/gems/1.9.1/gems/thin-1.6.3
tzinfo (0.3.42)
/var/lib/gems/1.9.1/gems/tzinfo-0.3.42
protected_attributes (1.0.3)
/var/lib/gems/1.9.1/gems/protected_attributes-1.0.3
daemons (1.1.9)
/var/lib/gems/1.9.1/gems/daemons-1.1.9
sprockets-rails (2.0.1)
/var/lib/gems/1.9.1/gems/sprockets-rails-2.0.1
activesupport (4.0.0)
/var/lib/gems/1.9.1/gems/activesupport-4.0.0
oauth (0.4.7)
/var/lib/gems/1.9.1/gems/oauth-0.4.7
numerizer (0.1.1)
/var/lib/gems/1.9.1/gems/numerizer-0.1.1
simplecov-html (0.8.0)
/var/lib/gems/1.9.1/gems/simplecov-html-0.8.0
omniauth (1.2.2)
~/.gem/ruby/1.9.1/gems/omniauth-1.2.2
spellingbee (0.0.2)
/var/lib/gems/1.9.1/gems/spellingbee-0.0.2
domain_name (0.5.23)
~/.gem/ruby/1.9.1/gems/domain_name-0.5.23
Hope this helps, thanks...
Mike
Hi,
I'd try to check "Run the script in context of bundle" option (go to Run|Edit Configurations, select run configuration, Bundler tab) perhaps it will help,
if this will not help please file a bug in our tracker (https://youtrack.jetbrains.com/issues/RUBY) and we will see what's wrong.
Regards, Oleg.