Class: ItchRewards::App

Inherits:
Dry::CLI
  • Object
show all
Defined in:
lib/itch_rewards/cli.rb

Instance Method Summary collapse

Instance Method Details

#usage(result) ⇒ Object



350
351
352
353
354
355
# File 'lib/itch_rewards/cli.rb', line 350

def usage(result)
  usage_prefix
  err.puts Usage.call(result)
  usage_suffix
  exit(1)
end

#usage_prefixObject



342
343
344
# File 'lib/itch_rewards/cli.rb', line 342

def usage_prefix
  err.puts "Usage: #{ProgramName.call()} COMMAND [options]\n\n"
end

#usage_suffixObject



346
347
348
# File 'lib/itch_rewards/cli.rb', line 346

def usage_suffix
  err.puts "\nGlobal options:\n  -h            # Show help for command"
end