Class: DenCli::Sub

Inherits:
Object
  • Object
show all
Defined in:
lib/pve/cli.rb

Instance Method Summary collapse

Instance Method Details

#provide_help(name: nil, aliases: nil, min: nil) ⇒ Object



18
19
20
21
22
23
24
25
# File 'lib/pve/cli.rb', line 18

def provide_help name: nil, aliases: nil, min: nil
  base = self
  name = :help  if name.nil?
  aliases = %w[-h --help]  if aliases.nil?
  min = 1  if min.nil?
  #p name: name, aliases: aliases, min: min
  cmd( name, '', aliases: aliases, min: min) {|*args| help *args }
end