diff options
Diffstat (limited to 'Library/Homebrew/cask/lib/hbc/artifact/base.rb')
| -rw-r--r-- | Library/Homebrew/cask/lib/hbc/artifact/base.rb | 10 |
1 files changed, 3 insertions, 7 deletions
diff --git a/Library/Homebrew/cask/lib/hbc/artifact/base.rb b/Library/Homebrew/cask/lib/hbc/artifact/base.rb index 2d9330b13..ae15552a4 100644 --- a/Library/Homebrew/cask/lib/hbc/artifact/base.rb +++ b/Library/Homebrew/cask/lib/hbc/artifact/base.rb @@ -1,6 +1,8 @@ module Hbc module Artifact class Base + extend Predicable + def self.artifact_name @artifact_name ||= name.sub(/^.*:/, "").gsub(/(.)([A-Z])/, '\1_\2').downcase end @@ -65,13 +67,7 @@ module Hbc {} end - def verbose? - @verbose - end - - def force? - @force - end + attr_predicate :force?, :verbose? def initialize(cask, command: SystemCommand, force: false, verbose: false) @cask = cask |
