aboutsummaryrefslogtreecommitdiffstats
path: root/Library/Homebrew/utils
diff options
context:
space:
mode:
Diffstat (limited to 'Library/Homebrew/utils')
-rw-r--r--Library/Homebrew/utils/inreplace.rb4
1 files changed, 2 insertions, 2 deletions
diff --git a/Library/Homebrew/utils/inreplace.rb b/Library/Homebrew/utils/inreplace.rb
index ee47da457..149994223 100644
--- a/Library/Homebrew/utils/inreplace.rb
+++ b/Library/Homebrew/utils/inreplace.rb
@@ -15,7 +15,7 @@ module Utils
# HOMEBREW_PREFIX is available in the embedded patch.
# inreplace supports regular expressions.
# <pre>inreplace "somefile.cfg", /look[for]what?/, "replace by #{bin}/tool"</pre>
- def inreplace(paths, before = nil, after = nil)
+ def inreplace(paths, before = nil, after = nil, audit_result = true)
errors = {}
Array(paths).each do |path|
@@ -25,7 +25,7 @@ module Utils
yield s
else
after = after.to_s if Symbol === after
- s.gsub!(before, after)
+ s.gsub!(before, after, audit_result)
end
errors[path] = s.errors if s.errors.any?