HEMANT SONKER'S BLOG

Sunday, December 2, 2007

Ruby---a programming language

Ruby is a cross-platform interpreted language, which has many features in common with other 'scripting' languages such as Perl and Python.

It has been desgined on the concept of "Principle of Least Surprise"
Yukihiro Matsumoto, commonly known as ‘Matz’ created the Ruby language in 1993.

If you are already familiar with object oriented programming, Ruby should quickly become second nature. If you've struggled with learning object-oriented programming or are not familiar with it, Ruby should make more sense to you than other object-oriented languages because Ruby's methods are consistently named, concise, and generally act the way you expect.

Ruby differs from most other programming languages not only by syntax, but by culture, grammar,and customs.

The Ruby on Rails Web framework is a system for developing Web applications
that uses Ruby as its base language, and it powers hundreds of large Web sites.
Ruby is also used as a generic language from the command prompt, much like Perl.

Installing Ruby

Windows users have access to an excellent “one-click installer,” which
installs Ruby, a horde of extensions, a source code editor, and various documentation, in
“one click.” Ruby on Windows is as reliable and useful as it is on other operating systems,
and Windows makes a good environment for developing Ruby programs.

To get up and running as quickly as possible, follow these steps:
1. Open a Web browser and go to http://www.ruby-lang.org/en/downloads/.
2. Scroll down to “Ruby on Windows,” about halfway down the page.
3. In the “Ruby on Windows” section, you’ll see a few links for different versions of
Ruby you can download for Windows. Ideally you want to download the file at the link that’s highest in the list that’s referred to as a “One-Click Installer.” At the time of writing, this is version 1.8.5.
4. Click the link you found in step 3 and save it to your desktop.
5. Once download has completed, look on your desktop for the Ruby EXE file you just downloaded, and double-click it to load the installer.
6. If Windows gives you a “Security Error” box, click the “Run” button to give your
approval.
7. A typical installation program appears with some instructions. On the initial
screen, click “Next.”
8. Work your way through the installation screens. Leave the boxes checked to install
the text editors SciTE , and the Ruby package manager RubyGems. Unless you have a specific reason not to, let the installation program install Ruby in its default location of c:\ruby and its default program group.
9. Installation takes place when you see a stream of filenames flying up your screen.
Wait several minutes for the installation process to complete and enjoy the view.
There are a lot of files to install!
10. Installation is complete when the installation program says “Installation Complete”
and the “Next” button is clickable. Click the “Next” button, then click
“Finish” to exit the installation program.
If Ruby installed correctly, congratulations! Go to the “Start” menu and then the “Programs”
or “All Programs” menu. There should be a Ruby program group that contains
icons for SciTE, an uninstaller, and other bits and pieces.
To test that your
Ruby installation works correctly, you need to load the program listed as
“fxri – Interactive Ruby Help & Console,” so click this entry and wait for the program to
load.If fxri started properly, then Ruby is installed correctly.

Congratulations! Lastly, you need to be familiar with running Ruby and its associated utilities from the command prompt, so go to the “Start” menu, then “Run,” and type cmd into the box and click “OK”.

3 Comments:

  • At Sunday, December 02, 2007 , Blogger David Mullet said...

    Nice intro, Hemant!

    "Ruby on Windows is as reliable and useful as it is on other operating systems, and Windows makes a good environment for developing Ruby programs."

    I very much agree, though I feel that there has not been enough written about using Ruby on Windows, which is why I created my Ruby on Windows blog.

    Feel free to stop by, post comments to my posts, or suggest topics for future posts.

    David

     
  • At Wednesday, December 19, 2007 , Blogger hemant said...

    thanks david,
    and sorry for replying late.

    yeah that is not sufficiently written,i just wanted to tell basically new people how it is installed in windows.
    you have great post written in your blog.

    Can you write on Rspec on Rails basically BDD. One more topic the people will like would be Rails 2.0.
    will love to see your posts.

    cheers
    hemant

     
  • At Tuesday, November 11, 2008 , Anonymous Anonymous said...

    You write very well.

     

Post a Comment

Subscribe to Post Comments [Atom]

<< Home