Skip to content
Browse files

Merge pull request #117 from tenderlove/opttable

stop using private constants
  • Loading branch information...
2 parents bd3589c + 2d08827 commit 50218b045a3352ed072ffec055cd49179467c69a @jimweirich committed Oct 13, 2012
Showing with 4 additions and 3 deletions.
  1. +4 −3 lib/rake/file_utils_ext.rb
View
7 lib/rake/file_utils_ext.rb
@@ -21,12 +21,13 @@ class << self
$fileutils_verbose = true
$fileutils_nowrite = false
- FileUtils::OPT_TABLE.each do |name, opts|
+ FileUtils.commands.each do |name|
+ opts = FileUtils.options_of name
default_options = []
- if opts.include?(:verbose) || opts.include?("verbose")
+ if opts.include?("verbose")
default_options << ':verbose => FileUtilsExt.verbose_flag'
end
- if opts.include?(:noop) || opts.include?("noop")
+ if opts.include?("noop")
default_options << ':noop => FileUtilsExt.nowrite_flag'
end

0 comments on commit 50218b0

Please sign in to comment.
Something went wrong with that request. Please try again.