Method: CommandKit::Commands::AutoLoad::Subcommand#initialize

Defined in:
lib/command_kit/commands/auto_load/subcommand.rb

#initialize(constant, path, summary: nil, **kwargs) ⇒ Subcommand

Initializes the lazy-loaded subcommand.

Parameters:

  • path (String)
  • constant (String)
  • summary (String, nil) (defaults to: nil)

    A short summary for the subcommand.

  • kwargs (Hash{Symbol => Object})

    Keyword arguments.

Options Hash (**kwargs):

  • aliases (Array<String>)

    Optional alias names for the subcommand.



44
45
46
47
48
49
# File 'lib/command_kit/commands/auto_load/subcommand.rb', line 44

def initialize(constant, path, summary: nil, **kwargs)
  @constant = constant
  @path     = path

  super(nil, summary: summary, **kwargs)
end