Reputation: 315
So, the title is quite self explanatory, but here's the following ..
rake db:create
rake aborted!
No rakefile found (looking for: rakefile, Rakefile, rakefile.rb, Rakefile.rb)
Any help would be appreciated.
Upvotes: 4
Views: 16774
Reputation: 4485
Case I:
Check out your directory. If you are in same directory where your application is available then you wont' get is this message. You are getting this message because you are out of your application directory. To check you present directory you can use this command
pwd
Case II
You might missing your Rakefile. Check it out in your directory. For example,
$ ls
app/
bin/
config/
db/
...
If you don't find Rakefile then create new one. Puts this code
# Add your own tasks in files placed in lib/tasks ending in .rake,
# for example lib/tasks/capistrano.rake, and they will automatically be available to Rake.
require File.expand_path('../config/application', __FILE__)
Blog::Application.load_tasks
Upvotes: 0
Reputation: 107
You have to be in the root of the Rails app that you are creating. Currently you must be one step up.
Upvotes: 3
Reputation: 324
What is your current working directory when calling the rake db:create command? Are you in the root of the Rails app?
Upvotes: 20