vendredi 17 avril 2015

Executing a ruby script on Windows 7 command line with multiple ruby files required

This might be a trivial question, but I've searched and found nothing about it. I'm trying to make a complex application on ruby and I have my classes on different .rb files which the "Main" class requires. As it's written in the code:



require 'Book.rb'
require 'Person.rb'


These files that contains the classes are in the same directory, so what I'm looking for is a Batch command which allows me to include these files, like the one for one file but extended:



ruby Main.rb


Which, of course fails saying that it can't find 'Book.rb' (returns error and doesn't look for the other)


Thank you for your help.


Aucun commentaire:

Enregistrer un commentaire