Module: Digicert::CLI::Util
- Defined in:
- lib/digicert/cli/util.rb
Class Method Summary collapse
- .make_it_pretty(headings:, rows:) ⇒ Object
- .run(arguments) ⇒ Object
- .say(message, color = nil) ⇒ Object
Class Method Details
.make_it_pretty(headings:, rows:) ⇒ Object
7 8 9 10 11 12 |
# File 'lib/digicert/cli/util.rb', line 7 def self.make_it_pretty(headings:, rows:) Terminal::Table.new do |table| table.headings = headings table.rows = rows end end |
.run(arguments) ⇒ Object
18 19 20 21 22 23 24 25 26 27 28 29 |
# File 'lib/digicert/cli/util.rb', line 18 def self.run(arguments) if arguments.include?("--debug") arguments.delete("--debug") Digicert.configuration.debug_mode = true Digicert::CLI::Command.start(arguments) Digicert.configuration.debug_mode = true else Digicert::CLI::Command.start(arguments) end end |
.say(message, color = nil) ⇒ Object
14 15 16 |
# File 'lib/digicert/cli/util.rb', line 14 def self.say(, color = nil) Thor::Shell::Basic.new.say(, color) end |