Pathname#write: don't check ARGV.force?

Closes Homebrew/homebrew#21390.
This commit is contained in:
Jack Nagel 2013-07-22 21:26:42 -05:00
parent 9942bcc21e
commit 1fb4cd501b

View File

@ -99,7 +99,7 @@ class Pathname
# we assume this pathname object is a file obviously # we assume this pathname object is a file obviously
def write content def write content
raise "Will not overwrite #{to_s}" if exist? and not ARGV.force? raise "Will not overwrite #{to_s}" if exist?
dirname.mkpath dirname.mkpath
File.open(self, 'w') {|f| f.write content } File.open(self, 'w') {|f| f.write content }
end end