Install Rails 4.0 with Ruby 2.0

Get the stable version of rvm:

$ rvm get stable

Install Ruby 2.0

$ rvm install ruby-2.0.0

Create a Gemset;

$ rvm gemset create rails-4.0

Goto that gemset:

$ rvm use ruby-2.0.0-p247@rails-4.0

Install Rails 4.0

$ gem install rails --version=4.0

Create an rvmrc file in root folder:

$ vim rvmrc
$ rvm --rvmrc use ruby-2.0.0-p247@rails-4.0

uncomment the line gem ‘therubyracer’, platforms: :ruby from Gemfile

Start the server:

$ rails s

You are ready to go!!

Changes that you may need to perform while working with Rails 4 compared to old versions:

1. Check here for the New changes in Rails 4
http://net.tutsplus.com/tutorials/ruby/digging-into-rails-4/
http://www.alfajango.com/blog/rails-4-whats-new/
http://www.sitepoint.com/get-your-app-ready-for-rails-4/
2. If you are using devise gem use devise version 3 or above (http://blog.plataformatec.com.br/2013/05/devise-and-rails-4/)

Advertisements

Author: Abhilash

Hi, this is Abhilash - Senior Programmer Analyst at CoMakeIT, specialised on web programming. Mainly working on Ruby On Rails platform since 2010.

2 thoughts on “Install Rails 4.0 with Ruby 2.0”

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s