Exception: Keg::ConflictError Private
Overview
This class is part of a private API. This class may only be used in the Homebrew/brew repository. Third parties should avoid using this class if possible, as it may be removed or changed without warning.
Error for when a file already exists or belongs to another keg.
Instance Attribute Summary
Attributes inherited from LinkError
Instance Method Summary collapse
- #suggestion ⇒ String private
Methods inherited from LinkError
Constructor Details
This class inherits a constructor from Keg::LinkError
Instance Method Details
#suggestion ⇒ String
This method is part of a private API. This method may only be used in the Homebrew/brew repository. Third parties should avoid using this method if possible, as it may be removed or changed without warning.
40 41 42 43 44 45 46 47 48 49 |
# File 'keg.rb', line 40 def suggestion conflict = Keg.for(dst) rescue NotAKegError, Errno::ENOENT "already exists. You may want to remove it:\n rm '#{dst}'\n" else <<~EOS is a symlink belonging to #{conflict.name}. You can unlink it: brew unlink #{conflict.name} EOS end |