I was having a little time on my hands and I thought I would try looking at Ruby.
Ruby is installed with OSX.
(I’ll post these links and information and tidy and format them up later. )
I’ve used the dollar sign $ to indicate the following text is to be entered into the Terminal window.
1. Download Ruby and place in Applications folder
2. Open the terminal
3. Launch Ruby and see prompt:
4. To create a Hello World application
I created a new folder – ruby in my Workspace
Created the following in a textfile:
saved as hello.rb in the ruby folder.
in the Terminal window:
$ ruby hello.rb
appears in the terminal window!
5. To make make executable:
(pronounced “sharp bang”) to the first line of the HelloWorld file
puts “Hello World”
6. The file needs to be ‘modified’ before the app can run:
( And ./ has to precede the fie name. )
The Terminal outputs:
6. EXAMPLES OF RUBY COMMANDS:
can give you information about a class.