O'Reilly Forums: Chp 1-Pg 8 - O'Reilly Forums

Jump to content

Page 1 of 1
  • You cannot start a new topic
  • You cannot reply to this topic

Chp 1-Pg 8 Starting Rails

#1 User is offline   Gunhee 

  • New Member
  • Pip
  • Group: Members
  • Posts: 1
  • Joined: 31-January 12

Posted 31 January 2012 - 10:11 PM

So after creating the new tickets folder, I am trying to "run ruby script/server".
However, whenever I run it, I get

"ruby: No such file or directory -- script/server (LoadError)"

If somebody could help, that would be great.
0

#2 User is offline   Joe Gillon 

  • New Member
  • Pip
  • Group: Members
  • Posts: 2
  • Joined: 10-February 12

Posted 10 February 2012 - 07:41 AM

View PostGunhee, on 31 January 2012 - 10:11 PM, said:

So after creating the new tickets folder, I am trying to "run ruby script/server".
However, whenever I run it, I get

"ruby: No such file or directory -- script/server (LoadError)"

If somebody could help, that would be great.


In case you haven't already figured this out, I'm pretty sure it's a version issue. I got my Ruby and Rails from RubyInstaller which installs the latest stuff and I also had this problem. Try

rails server

Later you run into the problem again, with the scaffold command which should be

rails generate scaffold etc.

There are a few more of these commands that want to use the script folder but just change them like the above two.

The next gotcha after that is in routing. Apparently the map.connect has changed quite a bit. Should be

match 'ads' => 'ads#index'
match 'ads/:id' => 'ads#show'

Now I'm trying to figure out why the css doesn't seem to be getting found...
0

#3 User is offline   Joe Gillon 

  • New Member
  • Pip
  • Group: Members
  • Posts: 2
  • Joined: 10-February 12

Posted 10 February 2012 - 09:14 AM

View PostGunhee, on 31 January 2012 - 10:11 PM, said:

So after creating the new tickets folder, I am trying to "run ruby script/server".
However, whenever I run it, I get

"ruby: No such file or directory -- script/server (LoadError)"

If somebody could help, that would be great.


Just figured out the css problem. You need to put it in the assets folder instead of the public folder. But the images stay in the public folder.
0

Share this topic:


Page 1 of 1
  • You cannot start a new topic
  • You cannot reply to this topic

1 User(s) are reading this topic
0 members, 1 guests, 0 anonymous users