From 5caef67a6f19e5c03cc4684532d738e02a694015 Mon Sep 17 00:00:00 2001 From: drbrain Date: Fri, 12 Aug 2011 16:56:48 +0000 Subject: * lib/rake: Update to Rake 0.9.2.2. Prevent pollution of toplevel namespace by Commands. Remove unused variable and debugging statement in tests. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@32948 b2dd03c8-39d4-4d8f-98ff-823fe69b080e --- lib/rake/application.rb | 1 + lib/rake/dsl_definition.rb | 8 +++++--- lib/rake/version.rb | 2 +- 3 files changed, 7 insertions(+), 4 deletions(-) (limited to 'lib/rake') diff --git a/lib/rake/application.rb b/lib/rake/application.rb index a4954f27e7..2079fb9be6 100644 --- a/lib/rake/application.rb +++ b/lib/rake/application.rb @@ -348,6 +348,7 @@ module Rake ], ['--rakelibdir', '--rakelib', '-R RAKELIBDIR', "Auto-import any .rake files in RAKELIBDIR. (default is 'rakelib')", + # HACK Use File::PATH_SEPARATOR lambda { |value| options.rakelib = value.split(':') } ], ['--require', '-r MODULE', "Require MODULE before executing rakefile.", diff --git a/lib/rake/dsl_definition.rb b/lib/rake/dsl_definition.rb index 3294f9e6c0..6d9a6b88f3 100644 --- a/lib/rake/dsl_definition.rb +++ b/lib/rake/dsl_definition.rb @@ -144,10 +144,12 @@ module Rake Rake.application.add_import(fn) end end + end + DeprecatedCommands = Object.new.extend(DSL) + module DeprecatedObjectDSL # :nodoc: - Commands = Object.new.extend DSL DSL.private_instance_methods(false).each do |name| line = __LINE__+1 class_eval %{ @@ -160,8 +162,8 @@ module Rake end $stderr.puts "WARNING: DSL method \#{self.class}##{name} called at \#{caller.first}" end - Rake::DeprecatedObjectDSL::Commands.send(:#{name}, *args, &block) - end + Rake::DeprecatedCommands.send(:#{name}, *args, &block) + end private :#{name} }, __FILE__, line end diff --git a/lib/rake/version.rb b/lib/rake/version.rb index 3afad7f25a..6c43493df9 100644 --- a/lib/rake/version.rb +++ b/lib/rake/version.rb @@ -1,5 +1,5 @@ module Rake - VERSION = '0.9.2.1' + VERSION = '0.9.2.2' module Version # :nodoc: all MAJOR, MINOR, BUILD = VERSION.split '.' -- cgit v1.2.3