diff options
Diffstat (limited to 'railties/lib/rails')
-rw-r--r-- | railties/lib/rails/application.rb | 10 | ||||
-rw-r--r-- | railties/lib/rails/generators/rails/app/templates/Gemfile | 2 | ||||
-rw-r--r-- | railties/lib/rails/railtie.rb | 1 |
3 files changed, 8 insertions, 5 deletions
diff --git a/railties/lib/rails/application.rb b/railties/lib/rails/application.rb index 816bff29b7..a7405aae16 100644 --- a/railties/lib/rails/application.rb +++ b/railties/lib/rails/application.rb @@ -185,10 +185,12 @@ module Rails end def initialize_tasks - require "rails/tasks" - task :environment do - $rails_rake_task = true - require_environment! + self.class.rake_tasks do + require "rails/tasks" + task :environment do + $rails_rake_task = true + require_environment! + end end end diff --git a/railties/lib/rails/generators/rails/app/templates/Gemfile b/railties/lib/rails/generators/rails/app/templates/Gemfile index 20bd9db624..5e1b4b0098 100644 --- a/railties/lib/rails/generators/rails/app/templates/Gemfile +++ b/railties/lib/rails/generators/rails/app/templates/Gemfile @@ -9,7 +9,7 @@ source 'http://rubygems.org' <%= "gem 'json'\n" if RUBY_VERSION < "1.9.2" -%> gem 'sass' gem 'coffee-script' -# gem 'uglifier' +gem 'uglifier' <%= gem_for_javascript %> diff --git a/railties/lib/rails/railtie.rb b/railties/lib/rails/railtie.rb index b183eb8ddd..0a65840c2b 100644 --- a/railties/lib/rails/railtie.rb +++ b/railties/lib/rails/railtie.rb @@ -178,6 +178,7 @@ module Rails end def load_tasks + extend Rake::DSL if defined? Rake::DSL self.class.rake_tasks.each(&:call) # load also tasks from all superclasses |