No Rakefile found when adding travis to a github project

I’m trying to add travis to my github project, and the build fails with:

$ rake
rake aborted!
No Rakefile found (looking for: rakefile, Rakefile, rakefile.rb, Rakefile.rb)
/home/travis/.rvm/gems/ruby-2.4.1/bin/ruby_executable_hooks:15:in `eval'
/home/travis/.rvm/gems/ruby-2.4.1/bin/ruby_executable_hooks:15:in `<main>'
(See full trace by running task with --trace)
The command "rake" exited with 1.

This is the most confusing error I’ve seen in several years, since I don’t have ruby in my project at all. I figured out that it’s basically “generic travis error” but that doesn’t help me figure out what’s wrong. There’s an answer on S/O that says to check the name of my file, but it is correct, it’s in the right branch, the formatting looks fine to me, and I have absolutely no leads on what to do next.
Here is my repository, this build is happening on the “develop” branch: https://github.com/tkondrashov/thisminute

Any help making this work would be very helpful, or any explanation of why travis doesn’t run checks to throw descriptive errors for things like whatever this is would at least make this less frustrating even if I have to find another CI tool.

Ah, it means “no language specified”, I figured it out.

I am getting the exact same issue. You say you figured it out, but what is the solution? What means “no language specified?”

You apparently have to have a language specified at the top of your .travis.yml file, for example I had to add
language: node_js

See: https://docs.travis-ci.com/user/tutorial/#selecting-a-different-programming-language

I have language mentioned in the travis.yml still it is throwing the same error…
any help please!!!

1 Like

Same with me, and it’s becominfg quit frustrating…

I’m developing with Docker, so I’ve set language: generic at the top of the file, and then
docker run -e CI=true <image_tag> npm run test -- --coverage for script…

Hi all,

I have a same error please can some one advise me…

$ rake
rake aborted!
No Rakefile found (looking for: rakefile, Rakefile, rakefile.rb, Rakefile.rb)

When reporting problems, please include relevant build URLs. Thanks.

In my case I pushed the .travis.yml empty to github. In your build check the commit code, go to your github repository and check if you pushed the .travis.yml to it. You might forget to save it before you pushed.

1 Like