Class: Awesomekit::CLI
- Inherits:
-
Thor
- Object
- Thor
- Awesomekit::CLI
- Includes:
- Thor::Actions
- Defined in:
- lib/awesomekit/cli.rb
Instance Method Summary collapse
Instance Method Details
#list ⇒ Object
19 20 21 22 23 24 25 26 27 28 29 30 |
# File 'lib/awesomekit/cli.rb', line 19 def list kits = typekit_client.get_kits ap(kits) if kits if [:verbose] kits.each do |kit| kit = typekit_client.get_kit(kit['id'], [:published]) ap(kit) if kit end end end |
#logout ⇒ Object
9 10 11 12 |
# File 'lib/awesomekit/cli.rb', line 9 def logout Awesomekit::Authenticator.clear_api_token ap('Successfully logged out', color: { string: :yellow }) end |
#show ⇒ Object
37 38 39 40 41 |
# File 'lib/awesomekit/cli.rb', line 37 def show kit = typekit_client.get_kit([:id], [:published]) ap(kit) if kit end |
#yo ⇒ Object
44 45 46 47 48 |
# File 'lib/awesomekit/cli.rb', line 44 def yo puts("What is your name? \n") name = STDIN.gets.chomp puts(" ~(0.0)~ \nyo #{name}, you seem pretty cool.\nYou should totally fork this repo and make it more awesome.\n") end |