Exception: Utils::InreplaceError

Inherits:
RuntimeError
  • Object
show all
Defined in:
brew/Library/Homebrew/utils/inreplace.rb

Instance Method Summary collapse

Constructor Details

#initialize(errors) ⇒ InreplaceError

Returns a new instance of InreplaceError



5
6
7
8
9
10
# File 'brew/Library/Homebrew/utils/inreplace.rb', line 5

def initialize(errors)
  formatted_errors = errors.reduce(+"inreplace failed\n") do |s, (path, errs)|
    s << "#{path}:\n" << errs.map { |e| "  #{e}\n" }.join
  end
  super formatted_errors.freeze
end