I feel really stupid about asking this, but how do i use the ruby interpreter provided here I have tried to find how on the site, in the readme and in the other documentation provided with the installation, but I am unable to find it. I have tried to use the command ruby directly drom the prompt, i have tried using the interactive, and i am completely lost.
Using the ruby interpreter?
Page 1 of 14 Replies - 1701 Views - Last Post: 29 October 2010 - 09:56 AM
Replies To: Using the ruby interpreter?
#2
Re: Using the ruby interpreter?
Posted 29 October 2010 - 08:35 AM
When you say you've tried using the ruby command and you've tried using the interactive do you mean that they never ran, or didn't run as you expected, or did run and you didn't know how to use them.
To run the ruby command, you need to give it a ruby file to interpret. Create your file, got to the folder where you put it in your command prompt/shell/terminal/whatever and type ruby <name of ruby file>.
To run interactive ruby just type irb in your command prompt or open it directly. If you need help getting started with interactive ruby I suggest checking out http://tryruby.org/ because it has a tutorial built in.
To run the ruby command, you need to give it a ruby file to interpret. Create your file, got to the folder where you put it in your command prompt/shell/terminal/whatever and type ruby <name of ruby file>.
To run interactive ruby just type irb in your command prompt or open it directly. If you need help getting started with interactive ruby I suggest checking out http://tryruby.org/ because it has a tutorial built in.
#3
Re: Using the ruby interpreter?
Posted 29 October 2010 - 09:45 AM
well, on my desktop, the ruby command doesnt work. On my laptop (Linux
) i dont remember what it says. just remember that i was unable to run the program. I navigated to the directory that my *.rb file was in (it was the hello world one) and I typed
ruby helloworld.rb. it gave me some kind of error, but i don't remember. i will try again tonight. Idk, i may have done something wrong, but didnt realize it.
#4
Re: Using the ruby interpreter?
Posted 29 October 2010 - 09:47 AM
You're probably going to need to add the path to the ruby interpreter to your environment variables. For your desktop anyway.
This post has been edited by SarumanTheWhite: 29 October 2010 - 09:49 AM
#5
Re: Using the ruby interpreter?
Posted 29 October 2010 - 09:56 AM
does Code:Blocks support ruby interpretation?
Page 1 of 1
|
|

New Topic/Question
Reply




MultiQuote



|