Why are some commands (e.g., generating a new controller or model) executed with the rails command? While others (e.g., migrating databases and running specs) executed with the rake command? Is there a reason these weren't just all included under rails? Also, if I can't remember w开发者_如何学运维hether a certain command is associated with rails or rake, is there a simple conceptual principle that would allow me to figure it out?
There's a conceptual difference between rails commands and rake commands.
rails commands add something to your application.
rake commands are for building/testing/deploying your application.
Those differences should explain both why there are two different commands as well as help you figure out which one to use for which tasks.
精彩评论