class BrewCaskTools::Tasks::CLI

Entrypoint for CLI

Public Class Methods

exit_on_failure?() click to toggle source
# File lib/bct/tasks.rb, line 19
def self.exit_on_failure?
  true
end
new(args, opts, config) click to toggle source
Calls superclass method
# File lib/bct/tasks.rb, line 13
def initialize(args, opts, config)
  super
  return if %w(help version).include?(config[:current_command].name)
  `brew update` # Update Caskroom tap so the latest formulae are pulled down
end

Public Instance Methods

cleanup(*casks) click to toggle source
# File lib/bct/tasks.rb, line 41
def cleanup(*casks)
  Tasks::Cleanup.new(casks)
end
outdated() click to toggle source
# File lib/bct/tasks.rb, line 29
def outdated
  Tasks::Outdated.new
end
upgrade(*casks) click to toggle source
# File lib/bct/tasks.rb, line 35
def upgrade(*casks)
  Tasks::Upgrade.new(casks)
end
version() click to toggle source
# File lib/bct/tasks.rb, line 24
def version
  say BrewCaskTools::VERSION, :green
end