Installing rails on ubuntu

Ruby on Rails is one of the most popular application stacks for developers wishing to create sites and web apps. The Ruby programming language, coupled with the Rails development framework, makes app development simple.

Since Ruby on Rails doesn't come in a neatly packaged format, getting the framework installed used to be one of the more difficult parts of getting started. Luckily, tools like rvm, the Ruby Version Manager, have made installation simple.

Before any other step install mpapis public key (might need gpg2) (see security)

gpg --keyserver hkp://keys.gnupg.net --recv-keys 

Install RVM (development version):

\curl -sSL https://get.rvm.io | bash

 you need to do is source the rvm scripts by typing:

source ~/.rvm/scripts/rvm

The Quick Way

The quickest way of installing Ruby on Rails with rvm is to run the following command as a regular user:

\curl -sSL https://get.rvm.io | bash -s stable --rails

You will be prompted for your regular user's password as part of the installation procedure.

The Long way

If you need to install specific versions of Ruby for your application, you can do so with rvm like this:

rvm install ruby_version

After the installation, we can list the available Ruby versions we have installed by typing:

rvm list

We can switch between the Ruby versions by typing:

rvm use ruby_version

For Installing rails

gem install rails

No comments:

Post a Comment

installing perl dancer in ubuntu

For installing perl dancer you need curl utility for installing curl ,   sudo apt-get install curl Now we can install Perl-Dancer by thi...