diff options
| author | Markus Reiter | 2016-09-24 13:52:43 +0200 |
|---|---|---|
| committer | Markus Reiter | 2016-09-24 16:00:58 +0200 |
| commit | b86c8efb79b3ed835d552c4d7416640ef10caf21 (patch) | |
| tree | 7e1edc8a8f339e4d2781f43576d40c9c79aebcdc /Library/Homebrew/cask/lib/hbc/cli/internal_checkurl.rb | |
| parent | 687f0fcf721c8e36f32570ed72d0988a6eaf986f (diff) | |
| download | brew-b86c8efb79b3ed835d552c4d7416640ef10caf21.tar.bz2 | |
Cask: Use nested classes and modules.
Diffstat (limited to 'Library/Homebrew/cask/lib/hbc/cli/internal_checkurl.rb')
| -rw-r--r-- | Library/Homebrew/cask/lib/hbc/cli/internal_checkurl.rb | 28 |
1 files changed, 16 insertions, 12 deletions
diff --git a/Library/Homebrew/cask/lib/hbc/cli/internal_checkurl.rb b/Library/Homebrew/cask/lib/hbc/cli/internal_checkurl.rb index d53f420e2..77cf250b1 100644 --- a/Library/Homebrew/cask/lib/hbc/cli/internal_checkurl.rb +++ b/Library/Homebrew/cask/lib/hbc/cli/internal_checkurl.rb @@ -1,15 +1,19 @@ -class Hbc::CLI::InternalCheckurl < Hbc::CLI::InternalUseBase - def self.run(*args) - casks_to_check = args.empty? ? Hbc.all : args.map { |arg| Hbc.load(arg) } - casks_to_check.each do |cask| - odebug "Checking URL for Cask #{cask}" - checker = Hbc::UrlChecker.new(cask) - checker.run - puts checker.summary - end - end +module Hbc + class CLI + class InternalCheckurl < InternalUseBase + def self.run(*args) + casks_to_check = args.empty? ? Hbc.all : args.map { |arg| Hbc.load(arg) } + casks_to_check.each do |cask| + odebug "Checking URL for Cask #{cask}" + checker = UrlChecker.new(cask) + checker.run + puts checker.summary + end + end - def self.help - "checks for bad Cask URLs" + def self.help + "checks for bad Cask URLs" + end + end end end |
