cask/installer: do not install tap during conflict checking
If the tap of the conflicted cask is not installed, we should just skip it. This matches the behavior of formula installation. Without this, running `brew install dropbox` would result to install the `homebrew/cask-versions` tap. Fixes #9125.
This commit is contained in:
parent
53ef74f674
commit
72a346e6c8
@ -120,6 +120,11 @@ module Cask
|
||||
return unless @cask.conflicts_with
|
||||
|
||||
@cask.conflicts_with[:cask].each do |conflicting_cask|
|
||||
if (match = conflicting_cask.match(HOMEBREW_TAP_CASK_REGEX))
|
||||
conflicting_cask_tap = Tap.fetch(match[1], match[2])
|
||||
next unless conflicting_cask_tap.installed?
|
||||
end
|
||||
|
||||
conflicting_cask = CaskLoader.load(conflicting_cask)
|
||||
raise CaskConflictError.new(@cask, conflicting_cask) if conflicting_cask.installed?
|
||||
rescue CaskUnavailableError
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user