Question

I've made a fresh installation of Ruby on Rails on my Windows 7 machine (using RailsInstaller) after a failed attempt to follow Michael Hartl's Ruby on Rails Tutorial (if you're interested, see my previous question pertaining to the said fail).

As I thought my previous fail had something to do with my inept attempt at installing different gem versions hoping to replicate requirements laid out in the tutorial, I decided to check the version of rails gem immediately after the install.

When I typed

rails -v

I got Rails 4.0.2 as a response, but when I did

gem list

it said rails (3.2.16), and that got me really confused.

Are we talking about two different things here?

Mind you that this is a crisp install: these two commands were the first, and the only two commands I ever typed.

Can this be the reason I couldn't boot WEBrick for my sample project?

Thanks!

Was it helpful?

Solution

The reason you are seeing this is the Railties executable wrapper is still installed. You need to uninstall the Rails gem and and the Railties gem.

$ gem uninstall rails
$ gem uninstall railties

You will likely be prompted to select which version of the gem to uninstall.

If needed, you can reinstall a specific version of Rails.

$ gem install rails -v 3.2.16
$ gem install railties -v 3.2.16

OTHER TIPS

gem list will show all gems you've installed. If you have multiple versions of rails installed it will show them.

Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top