Odd error


#1

Hello everybody.

I have just started trying rails, got instant rails and radrails… Made
a new project, and when I tried to create a model I get the following
error:

Project> ruby script/generate model user -h

-e:3:in `load’: no such file to load – script/generate (LoadError)

        from -e:3

I´m sure this is a newbie question, I´ve searched the documentation and
couldn´t find what I am doing wrong.

Best regards,

Mariano


#2

Make sure you open your console window through Instant Rails (I>Rails
Applications>Open Ruby Console Window).

This is important because it makes sure that the INstant Rails
ruby\bin directory is on your path.

Curt


#3

Hi Mariano!

You need to declare in RadRails in Window-> Preferences the path to
Ruby, and Rails, of course, as follows:

for Ruby : Window->Preferences->Ruby->Installed Interpreter->Add :
Name: ruby ; Location: d:\work\instantRails\ruby\bin\ruby.exe
(modify the path with yours one)
for Rails: Window->Preferences->Rails->Rails Installs -> Add : Name:
rails; Location: *d:\work\instantRails\ruby *(the same as above,
modify the path… do not add any bin subfolder here :slight_smile: )

Recreate your project and you’ll see that it will create the skeleton
and the model creation will work.

Greetings,

Dan.