What is the Ruby On Rails and How install?

Ruby

  • Object oriented programming language
  • Created in 1995 by Matz
  • Used for many purpose, not only web app.

Ruby on Rails

  • Open source, web applications framework.
  • Written in Ruby
  • Release as open source in 2004

How install Ruby On Rails?

Firstly, you have to install ruby, and then start install rails. Is there ruby in your pc? Look at!

1
2
ruby -v
# ruby 2.0.0p353 (2013-11-22 revision 43784) [x86_64-darwin13.0.0]

I hear , ‘my pc don’t has ruby.’ Dont worry, when you are going to download ruby. Now, we install the ruby after then

1
gem update system

start install rails framework.

1
gem install rails

rails was install and which version?

1
2
rails --version  or rails -v
# Rails 4.0.2

Yeah!, now pc has ruby and rails.

Then we can start to create Ruby on Rails project.

1
rails new start_rails_project

Created rails project. That’s very easy!

Go to rails project path and install bundler

1
2
gem install bundle
bundle install

Now, you can write your ruby code on rails framework . How run your rails applications ?

We should write

    rails server or rails s

In terminal, you should see this url ‘http://0.0.0.0:3000’ and copy this, paste on your search bar.

You can see Ruby default information page

Default page

Yeah, Installed Ruby On Rails and started to code your rails applications.

If you want to learn more, you should visit rubyonrails.

Comments