Class: Manga::Tools::CLI
- Inherits:
-
Thor
- Object
- Thor
- Manga::Tools::CLI
- Defined in:
- lib/manga/tools/cli.rb
Overview
CLI class
Constant Summary collapse
- HOST_OPTION =
{ aliases: '-h', desc: 'Specifies the host to connect to for development' }.freeze
Class Method Summary collapse
Instance Method Summary collapse
Class Method Details
.exit_on_failure? ⇒ Boolean
14 15 16 |
# File 'lib/manga/tools/cli.rb', line 14 def self.exit_on_failure? true end |
Instance Method Details
#follow(key) ⇒ Object
28 29 30 31 32 |
# File 'lib/manga/tools/cli.rb', line 28 def follow(key) client = Manga::Tools::Client.new results = client.follow(key, ) Manga::Tools::Formatter.display(:follow, key, results) end |
#follow_list ⇒ Object
36 37 38 39 40 |
# File 'lib/manga/tools/cli.rb', line 36 def follow_list client = Manga::Tools::Client.new results = client.follow_list() Manga::Tools::Formatter.display(:follow_list, results) end |
#search(word) ⇒ Object
20 21 22 23 24 |
# File 'lib/manga/tools/cli.rb', line 20 def search(word) client = Manga::Tools::Client.new results = client.search(word, ) Manga::Tools::Formatter.display(:search, word, results) end |