class FIR::CLI
Public Instance Methods
build_apk(*args)
click to toggle source
# File lib/fir/cli.rb, line 76 def build_apk(*args) prepare :build_apk FIR.build_apk(*args, options) end
build_ipa(*args)
click to toggle source
# File lib/fir/cli.rb, line 45 def build_ipa(*args) prepare :build_ipa FIR.build_ipa(*args, options) end
help(command = nil, subcommand = false)
click to toggle source
Calls superclass method
# File lib/fir/cli.rb, line 168 def help(command = nil, subcommand = false) super end
info(*args)
click to toggle source
# File lib/fir/cli.rb, line 85 def info(*args) prepare :info FIR.info(*args, options) end
invoke_command(command, *args)
click to toggle source
Calls superclass method
# File lib/fir/cli.rb, line 173 def invoke_command(command, *args) logfile = options[:logfile].blank? ? STDOUT : options[:logfile] logfile = '/dev/null' if options[:quiet] FIR.logger = Logger.new(logfile) FIR.logger.level = options[:verbose] ? Logger::INFO : Logger::ERROR super end
login(*args)
click to toggle source
# File lib/fir/cli.rb, line 119 def login(*args) prepare :login token = options[:token] || args.first || ask('Please enter your fir.im API Token:', :white, echo: true) FIR.login(token) end
mapping(*args)
click to toggle source
# File lib/fir/cli.rb, line 145 def mapping(*args) prepare :mapping FIR.mapping(*args, options) end
me()
click to toggle source
# File lib/fir/cli.rb, line 127 def me prepare :me FIR.me end
publish(*args)
click to toggle source
# File lib/fir/cli.rb, line 111 def publish(*args) prepare :publish FIR.publish(*args, options) end
upgrade()
click to toggle source
# File lib/fir/cli.rb, line 153 def upgrade prepare :upgrade say '✈ Upgrade fir-cli (use `gem install fir-cli --no-ri --no-rdoc`)' say `gem install fir-cli --no-ri --no-rdoc` end
version()
click to toggle source
# File lib/fir/cli.rb, line 162 def version say "✈ fir-cli #{FIR::VERSION}" end
Private Instance Methods
prepare(task)
click to toggle source
# File lib/fir/cli.rb, line 185 def prepare(task) if options.help? help(task.to_s) fail SystemExit end $DEBUG = true if ENV['DEBUG'] end