Module: Konjac::CLI
- Defined in:
- lib/konjac/cli.rb
Class Method Summary collapse
Class Method Details
.show_help ⇒ Object
19 20 21 22 |
# File 'lib/konjac/cli.rb', line 19 def show_help puts "Help" exit 0 end |
.start ⇒ Object
4 5 6 7 8 9 10 11 12 13 14 15 16 17 |
# File 'lib/konjac/cli.rb', line 4 def start show_help if ARGV.empty? # Subcommand case ARGV.shift when "translate" translate when "add" when "help" show_help else raise ArgumentError.new("Valid commands are translate or add") end end |