How to directly use "app.get" in rake?

now I use:
echo ‘app.get “/”’|./script/console production

and,how to use ‘app.get’ in rake file directly?

OK,try it in rakefile:

require ‘action_controller’
require ‘console_app’
task :demo=>:environment do
puts app.get “/”
end

1>add :environment after task name(:demo)
2>then require ‘console_app’ in block

task :demo=>:environment do
require ‘console_app’
puts app.get “/”
#puts app.response.body
end

that’s it!