You have to save the file with the extension *.rb, then open your 
terminal, place your working zone in the path you have your file saved, 
then run it like this:

ruby something.rb

-- 
Posted via http://www.ruby-forum.com/.