October 26, 2014

Home » » Install Ruby On Windows or Linux

Install Ruby On Windows or Linux

Posted by Unknown
0

I.  Ruby Overview

RubyInstaller

II. Install Ruby

  • In Windows
      Download and Install
    • Download rubyinstaller
    • Double click rubyinstaller.exe to install.
      Run
    • Finished, go to run -> cmd -> irb or run Interactive Ruby
  • In Linux
      Install with yum
    • # yum install ruby
      Install other way
    • $ rpm -ivh install wget #Install wget for download package from internet
    • $ cd /tmp
    • $ wget > <source> /ruby-2.x.x #Download ruby from internet
    • $ rpm -ivh install ruby-2.x.x or $ yum install ruby-2.x.x
      Run
    • Finished, go to Terminal and enter irb

III. Test install

$ ruby -v
$ ruby -e "puts  'Hello World! '"

IV. More

Similar man command in shell, in ruby using ri command :
  # using ri command 
$ ri puts  # press q to quit 
Using Editor:
  • # In Windows notepad++, RubyWin,...
  • # In Linux vim, gedit, ...





0 comments:

Post a Comment

Popular Posts

Labels

Archive

 

Blogroll

Recepies

Flickr Images

Copyright © 2014. Tutorials Blog - All Rights Reserved