diff options
| author | Markus Reiter | 2016-09-24 17:58:59 +0200 |
|---|---|---|
| committer | GitHub | 2016-09-24 17:58:59 +0200 |
| commit | 0ba19c852bb4b999eff9d8475ee762da902b20d8 (patch) | |
| tree | 551a717d238f0953ba4b36296608ba09f248624e /Library/Homebrew/cask/lib/hbc/without_source.rb | |
| parent | 6eebea452517f421f180d84d41cdce808351ec44 (diff) | |
| parent | b86c8efb79b3ed835d552c4d7416640ef10caf21 (diff) | |
| download | brew-0ba19c852bb4b999eff9d8475ee762da902b20d8.tar.bz2 | |
Merge pull request #1118 from reitermarkus/cask-nested-classes-and-modules
Cask: Use nested classes and modules.
Diffstat (limited to 'Library/Homebrew/cask/lib/hbc/without_source.rb')
| -rw-r--r-- | Library/Homebrew/cask/lib/hbc/without_source.rb | 24 |
1 files changed, 13 insertions, 11 deletions
diff --git a/Library/Homebrew/cask/lib/hbc/without_source.rb b/Library/Homebrew/cask/lib/hbc/without_source.rb index 6ed826e41..69131d5c7 100644 --- a/Library/Homebrew/cask/lib/hbc/without_source.rb +++ b/Library/Homebrew/cask/lib/hbc/without_source.rb @@ -1,15 +1,17 @@ -class Hbc::WithoutSource < Hbc::Cask - # Override from `Hbc::DSL` because we don't have a cask source file to work - # with, so we don't know the cask's `version`. - def staged_path - (caskroom_path.children - [metadata_master_container_path]).first - end +module Hbc + class WithoutSource < Cask + # Override from `Hbc::DSL` because we don't have a cask source file to work + # with, so we don't know the cask's `version`. + def staged_path + (caskroom_path.children - [metadata_master_container_path]).first + end - def to_s - "#{token} (!)" - end + def to_s + "#{token} (!)" + end - def installed? - caskroom_path.exist? + def installed? + caskroom_path.exist? + end end end |
