Class: FIR::CLI

Inherits:
Thor show all
Defined in:
lib/fir/cli.rb

Instance Method Summary collapse

Instance Method Details

#build_apk(*args) ⇒ Object



58
59
60
61
62
# File 'lib/fir/cli.rb', line 58

def build_apk *args
  prepare :build_apk

  FIR.build_apk(*args, options)
end

#build_ipa(*args) ⇒ Object



37
38
39
40
41
# File 'lib/fir/cli.rb', line 37

def build_ipa *args
  prepare :build_ipa

  FIR.build_ipa(*args, options)
end

#help(command = nil, subcommand = false) ⇒ Object



145
146
147
# File 'lib/fir/cli.rb', line 145

def help command = nil, subcommand = false
  super
end

#info(*args) ⇒ Object



67
68
69
70
71
# File 'lib/fir/cli.rb', line 67

def info *args
  prepare :info

  FIR.info(*args, options)
end

#login(*args) ⇒ Object



96
97
98
99
100
101
# File 'lib/fir/cli.rb', line 96

def  *args
  prepare :login

  token = options[:token] || args.first || ask("Please enter your FIR.im API Token:", :white, echo: true)
  FIR.(token)
end

#mapping(*args) ⇒ Object



122
123
124
125
126
# File 'lib/fir/cli.rb', line 122

def mapping *args
  prepare :mapping

  FIR.mapping(*args, options)
end

#me(*args) ⇒ Object



104
105
106
107
108
# File 'lib/fir/cli.rb', line 104

def me *args
  prepare :me

  FIR.me
end

#publish(*args) ⇒ Object



88
89
90
91
92
# File 'lib/fir/cli.rb', line 88

def publish *args
  prepare :publish

  FIR.publish(*args, options)
end

#upgradeObject



130
131
132
133
134
135
# File 'lib/fir/cli.rb', line 130

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

#versionObject



139
140
141
# File 'lib/fir/cli.rb', line 139

def version
  say "✈ FIR-CLI #{FIR::VERSION}"
end