Learning Ruby

I am using Beginning Ruby on Rails. The code samples in the book do not
seem to work ‘as is’.

For example, this command, “ruby script/generate controller App” gives
this error:
ruby: No such file or directory – script/generate (LoadError)

Why is that?

You’re using an old tutorial, rails doesn’t use script/generate anymore,
it’s just generate.