为什么我得到"RAKEFILE ABORTED,NO RAKEFILE FOUND"?

use*_*627 3 ruby rakefile

我试图进行交互式Ruby测试无济于事.

我没有问题地下载了zip文件,并按照终端命令行的说明继续得到以下错误.我使用的是"Ruby 1.9.3p392(2013-02-22修订版39386)[x86_64-darwin10.8.0]".

如果有人可以提供任何帮助或建议,请提前感谢您.

INSTRUCTIONS:

Install RSpec

  gem install rspec

Enter the course directory. (That's the same directory that this
index.html file is in.)

  cd learn_ruby

Enter the 00_hello lab.

  cd 00_hello

Open a terminal in this directory

cd 00_hello

This directory is the starting point for this exercise. It contains a
spec file and you'll be adding a ruby file to (eventually) make the
specs pass.

Run the test

  rake

Watch it fail

You should see an error. Don't get scared! Try to read it and figure out
what the computer wants to tell you. Somewhere on the first line it
should say something like

no such file to load -- test-first-teaching/hello/hello (LoadError)
Run Code Online (Sandbox Code Playgroud)

我没有收到此错误消息,我得到以下一个:

rake aborted!
No Rakefile found (looking for: rakefile, Rakefile, rakefile.rb,
Rakefile.rb)
/usr/local/rvm/gems/ruby-1.9.3-p392/bin/ruby_noexec_wrapper:14:in `eval'
/usr/local/rvm/gems/ruby-1.9.3-p392/bin/ruby_noexec_wrapper:14:in
`<main>'
(See full trace by running task with --trace)
Run Code Online (Sandbox Code Playgroud)

当我跑步时,rake --trace我收到:

rake --trace
rake aborted!
No Rakefile found (looking for: rakefile, Rakefile, rakefile.rb,
Rakefile.rb)
/usr/local/rvm/gems/ruby-1.9.3-p392/gems/rake-10.1.0/lib/rake/application.rb:632:in
`raw_load_rakefile'
/usr/local/rvm/gems/ruby-1.9.3-p392/gems/rake-10.1.0/lib/rake/application.rb:94:in
`block in load_rakefile'
/usr/local/rvm/gems/ruby-1.9.3-p392/gems/rake-10.1.0/lib/rake/application.rb:165:in
`standard_exception_handling'
/usr/local/rvm/gems/ruby-1.9.3-p392/gems/rake-10.1.0/lib/rake/application.rb:93:in
`load_rakefile'
/usr/local/rvm/gems/ruby-1.9.3-p392/gems/rake-10.1.0/lib/rake/application.rb:77:in
`block in run'
/usr/local/rvm/gems/ruby-1.9.3-p392/gems/rake-10.1.0/lib/rake/application.rb:165:in
`standard_exception_handling'
/usr/local/rvm/gems/ruby-1.9.3-p392/gems/rake-10.1.0/lib/rake/application.rb:75:in
`run'
/usr/local/rvm/gems/ruby-1.9.3-p392/gems/rake-10.1.0/bin/rake:33:in
`<top (required)>'
/usr/local/rvm/gems/ruby-1.9.3-p392/bin/rake:19:in `load'
/usr/local/rvm/gems/ruby-1.9.3-p392/bin/rake:19:in `<main>'
/usr/local/rvm/gems/ruby-1.9.3-p392/bin/ruby_noexec_wrapper:14:in `eval'
/usr/local/rvm/gems/ruby-1.9.3-p392/bin/ruby_noexec_wrapper:14:in
`<main>'
Run Code Online (Sandbox Code Playgroud)

Con*_*ech 9

你必须先进入你的项目目录才能运行rake路由