首页
学习
活动
专区
圈层
工具
发布
社区首页 >问答首页 >为什么我得到"RAKEFILE中止,找不到RAKEFILE“?

为什么我得到"RAKEFILE中止,找不到RAKEFILE“?
EN

Stack Overflow用户
提问于 2013-08-04 22:46:26
回答 1查看 8.9K关注 0票数 3

我正在尝试一个交互式的Ruby测试,但没有用。

我毫无问题地下载了zip文件,并按照终端命令行的说明进行操作,但仍然出现以下错误。我使用的是"Ruby 1.9.3p392 (2013.02-22 revision 39386) x86_64-darwin10.8.0“。

如果有人能提供任何帮助或建议,请提前表示感谢。

代码语言:javascript
复制
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)

我没有收到这个错误消息,我收到的错误消息如下:

代码语言:javascript
复制
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)

当我运行rake --trace时,我接收到:

代码语言:javascript
复制
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>'
EN

回答 1

Stack Overflow用户

发布于 2013-08-12 23:30:17

在运行rake路径之前,您必须先cd到项目目录中

票数 9
EN
页面原文内容由Stack Overflow提供。腾讯云小微IT领域专用引擎提供翻译支持
原文链接:

https://stackoverflow.com/questions/18044174

复制
相关文章

相似问题

领券
问题归档专栏文章快讯文章归档关键词归档开发者手册归档开发者手册 Section 归档