Permalink
Browse files

Fix compatibility with Rake 0.9.x.

This method is incredibly unsatisfactory, please see:

 * jimweirich/rake#81

for more discussion about this issue.
  • Loading branch information...
1 parent c11cfec commit bd6ff00fa3f520dbe712c95e03db6785c58b35df @leehambley leehambley committed Feb 19, 2012
Showing with 10 additions and 0 deletions.
  1. +2 −0 lib/capistrano.rb
  2. +8 −0 lib/capistrano/fix_rake_deprecated_dsl.rb
View
@@ -1,3 +1,5 @@
+require 'capistrano/fix_rake_deprecated_dsl'
+
require 'capistrano/configuration'
require 'capistrano/extensions'
require 'capistrano/ext/string'
@@ -0,0 +1,8 @@
+#
+# See https://github.com/jimweirich/rake/issues/81
+#
+if defined?(Rake::DeprecatedObjectDSL)
+ Rake::DeprecatedObjectDSL.private_instance_methods.each do |m|
+ Rake::DeprecatedObjectDSL.send("undef_method", m)
+ end
+end

0 comments on commit bd6ff00

Please sign in to comment.