diff options
Diffstat (limited to 'Library/Homebrew/cask/lib/hbc/artifact.rb')
| -rw-r--r-- | Library/Homebrew/cask/lib/hbc/artifact.rb | 16 |
1 files changed, 11 insertions, 5 deletions
diff --git a/Library/Homebrew/cask/lib/hbc/artifact.rb b/Library/Homebrew/cask/lib/hbc/artifact.rb index b155a125a..074d15017 100644 --- a/Library/Homebrew/cask/lib/hbc/artifact.rb +++ b/Library/Homebrew/cask/lib/hbc/artifact.rb @@ -25,10 +25,17 @@ require "hbc/artifact/zap" module Hbc module Artifact - # NOTE: order is important here, since we want to extract nested containers - # before we handle any other artifacts + # NOTE: Order is important here! + # + # The `uninstall` stanza should be run first, as it may + # depend on other artifacts still being installed. + # + # We want to extract nested containers before we + # handle any other artifacts. + # TYPES = [ PreflightBlock, + Uninstall, NestedContainer, Installer, App, @@ -49,17 +56,16 @@ module Hbc VstPlugin, Vst3Plugin, ScreenSaver, - Uninstall, PostflightBlock, Zap, ].freeze - def self.for_cask(cask, command: SystemCommand, force: false) + def self.for_cask(cask, options = {}) odebug "Determining which artifacts are present in Cask #{cask}" TYPES .select { |klass| klass.me?(cask) } - .map { |klass| klass.new(cask, command: command, force: force) } + .map { |klass| klass.new(cask, options) } end end end |
