stopshinal
stopshinal

Reputation: 1921

Installing Rails with RVM, while checking rail -v: bundler-1.1.5 conflicts with bundler (~> 1.0.0)

I'm having a dearly hard time getting my rails environment up. Here is the issue.

$ gem install rails --version 3.0.1

Successfully installed rails-3.0.1
1 gem installed
Installing ri documentation for rails-3.0.1...
Installing RDoc documentation for rails-3.0.1...

$ rails -v

/.rvm/rubies/ruby-1.9.2-p320/lib/ruby/site_ruby/1.9.1/rubygems/specification.rb:1637:in `raise_if_conflicts': **Unable to activate rails-3.0.1, because bundler-1.1.5 conflicts with bundler (~> 1.0.0) (Gem::LoadError)**
    from /.rvm/rubies/ruby-1.9.2-    p320/lib/ruby/site_ruby/1.9.1/rubygems/specification.rb:746:in `activate'
    from /.rvm/rubies/ruby-1.9.2-p320/lib/ruby/site_ruby/1.9.1/rubygems.rb:1232:in `gem'
    from /.rvm/gems/ruby-1.9.2-p320@rails3tutorial/bin/rails:18:in `<main>'
    from /.rvm/gems/ruby-1.9.2-p320@rails3tutorial/bin/ruby_noexec_wrapper:14:in `eval'
    from /.rvm/gems/ruby-1.9.2-p320@rails3tutorial/bin/ruby_noexec_wrapper:14:in `<main>'

Here in lies the issue. I've reinstalled ruby. I've installed 1.8.7, 1.9.2, 1.9.3 and still no luck across the board.

i've run $ gem update bundler

But bundle is 'up to date', so still no luck

I've really poked at this all day now, and with no luck I open my palms to you all.

Upvotes: 1

Views: 761

Answers (1)

mpapis
mpapis

Reputation: 53178

the issue is that in @global gemset you have higher version of bundler then the one required.

you can either specify the version on command line:

bundle _1.0.27_ exec rails -v

or use Gemfile:

printf 'source :rubygems\ngem "rails", "3.0.1"\n'
rails -v

this assumed you have the gem rubygems-bundler - but it comes by default with RVM so you should have it.

and last - remove bundler from @global:

rvm @global do gem uninstall bundler

but there is one caveat - while reinstalling ruby gem bundler will be installed again.

Upvotes: 1

Related Questions