Class: Hodlmoon::Cli
- Inherits:
-
Thor
- Object
- Thor
- Hodlmoon::Cli
- Defined in:
- lib/hodlmoon/cli.rb
Constant Summary collapse
- DEFAULT_LIMIT =
8
- CURRENCY =
{ gbp: '£', usd: '$', eur: '€' }.freeze
Instance Method Summary collapse
- #hello(name) ⇒ Object
- #list(limit = DEFAULT_LIMIT, currency = 'gbp') ⇒ Object
- #price(coin, currency = 'gbp') ⇒ Object
Instance Method Details
#hello(name) ⇒ Object
17 18 19 |
# File 'lib/hodlmoon/cli.rb', line 17 def hello(name) puts "Hello #{name}" end |
#list(limit = DEFAULT_LIMIT, currency = 'gbp') ⇒ Object
28 29 30 31 |
# File 'lib/hodlmoon/cli.rb', line 28 def list(limit = DEFAULT_LIMIT, currency = 'gbp') info = Hodlmoon::Client::RetrieveList.call(limit, currency) puts Hodlmoon::Table.build(info, currency) end |