module Rails::Generators::Actions

def rake(command, options = {})

Whether to run the task using +sudo+.
[+:sudo+]

Whether to capture and return the output of the task.
[+:capture+]

exit status.
Whether to halt the generator if the task exits with a non-success
[+:abort_on_failure+]

ENV["RAILS_ENV"] || "development".
The Rails environment in which to run the task. Defaults to
[+:env+]

==== Options

rake "gems:install", sudo: true
rake "stats", capture: true
rake "db:migrate", abort_on_failure: true
rake "db:migrate", env: "production"
rake "db:migrate"

Runs the specified Rake task.
def rake(command, options = {})
  execute_command :rake, command, options
end