|
|
Question : Installed Ruby on Instant Rails fine and the cookbook workd but can't seem to get a new app to work...
|
|
Hi, I'm brand new to trying to learn ROR. I just downloaded and installed Ruby on Instant Rails and all went well... I believe... Cookbook app included w/ Ruby on Instant Rails v2.02 works fine after install.
Next I set up a new app: my_app chose my Instant Rails "rails_apps" subdirectory as my workspace but of course down one level into the my_app subdirectory Fired it up my_app (Mongrel running) and next want to setup a controller... here is where I'm having problems.
When I open a Ruby console window and navigate into my new my_app subdirectory and start typing commands.... nothing seems to be working. Even up a level from my my_app subdirectory in the rails_apps directory no commands work here either.
What is my problem.....????? HELP APPRECIATED!
THX Rip
|
Answer : Installed Ruby on Instant Rails fine and the cookbook workd but can't seem to get a new app to work...
|
|
First, make sure you open a console window using the InstantRails option "Open Ruby Console Window" by right-clicking the red I in the system tray. That loads all the ruby/mysql paths.
An easy way to check is type: > ruby -v It should return "ruby 1.8.6" or something like that. If it doesn't, then you don't have ruby on the path so it can't be found to run your ruby script!
Next, on windows, you normally have to provide the program name, then the command: ruby script/generate Say
Windows doesn't support she-bangs (where the program that runs a file is on the first line of the file: #!/usr/local/bin"
So, if you can run "ruby -v" and try the command with the ruby name in front of it, that should do the trick.
If not, let us know what error you're getting and we'll go from there.
|
|
|
|
|