3

I'm following Head First Ruby, and found out that the server file inside the script folder of my first project is missing. I followed this Ubuntu installation tutorial (sorry, Spanish link, still should be easy to follow the commands) and I guess some files/packages are missing. How I can get them?

antonio@antonio-desktop:~/Documents/tickets$ ruby script/server
ruby: No such file or directory -- script/server (LoadError)
antonio@antonio-desktop:~/Documents/tickets$ ls
app     config.ru  doc      lib  public    README  test  vendor
config  db         Gemfile  log  Rakefile  script  tmp
antonio@antonio-desktop:~/Documents/tickets$ cd script
antonio@antonio-desktop:~/Documents/tickets/script$ ls
rails
Trott
  • 66,479
  • 23
  • 173
  • 212
andandandand
  • 21,946
  • 60
  • 170
  • 271
  • Rails version? In rails 3.x there isn't a script/server file... – lucapette Aug 31 '11 at 21:27
  • @lucapette: Its Rails 3.1. You think should I dump the book and read straight out of the documentation? Have significant changes occurred? The command to create the project has changed from what appears on the book. – andandandand Aug 31 '11 at 21:34
  • 1
    Rails 2.X and Rails 3.x are different in many things. So, if you're starting now go straight to official documentation. – lucapette Aug 31 '11 at 21:36

1 Answers1

3

If you're running Rails 3, it's now:

./script/rails server

All of the separate rails scripts in the scripts directory run through the single ./script/rails dispatcher now. This works for the console and other things you may be looking for as well (ie: ./script/rails console).

Winfield
  • 18,985
  • 3
  • 52
  • 65