Method: Pry::CommandSet#initialize

Defined in:
lib/pry/command_set.rb

#initialize(*imported_sets) { ... } ⇒ CommandSet

Returns a new instance of CommandSet.

Parameters:

  • imported_sets (Array<Commandset>)

    Sets which will be imported automatically

Yields:

  • Optional block run to define commands



20
21
22
23
24
25
# File 'lib/pry/command_set.rb', line 20

def initialize(*imported_sets, &block)
  @commands      = {}
  @helper_module = Module.new
  import(*imported_sets)
  instance_eval(&block) if block
end