Can't run files in irb on c9



I am having difficulty running my files through irb on my c9 workspace.

basically in ~workspace > irb -I. leads to irb just fine

username:~/workspace $ irb -I.
2.3.0 :001 > ruby "test.rb"
NoMethodError: undefined method ruby' for main:Object from (irb):1 from /usr/local/rvm/rubies/ruby-2.3.0/bin/irb:11:in

test.rb is in worspace and its syntax is right as far as I can tell…
please help. I have never had this problem before.


ruby is not a function defined in irb. run it from bash, or run load filename in irb . see


Yes. I should have known better. Growing of a noob…

Maybe the following will help some else (noob) down the road?

username:~/workspace $ irb -I.
2.3.0 :001 > require “test.rb”

TERMINAL (aka RUNNING a program)
username:~/workspace $ ruby file.rb ->notice absence of quotes when running a .rb