Load application specific rake tasks in the application object

This commit is contained in:
Carl Lerche 2009-11-25 14:29:28 -08:00
parent 71a6b0465b
commit 34eac1cf1c
2 changed files with 2 additions and 5 deletions

View File

@ -29,6 +29,8 @@ module Rails
def load_tasks
require "rails/tasks"
Dir["#{root}/vendor/plugins/*/**/tasks/**/*.rake"].sort.each { |ext| load ext }
Dir["#{root}/lib/tasks/**/*.rake"].sort.each { |ext| load ext }
task :environment do
$rails_rake_task = true
initialize!

View File

@ -16,8 +16,3 @@ $VERBOSE = nil
).each do |task|
load "rails/tasks/#{task}.rake"
end
# Load any custom rakefile extensions
# TODO: Don't hardcode these paths.
Dir["#{Rails.root}/vendor/plugins/*/**/tasks/**/*.rake"].sort.each { |ext| load ext }
Dir["#{Rails.root}/lib/tasks/**/*.rake"].sort.each { |ext| load ext }