Method: Shell::Extensions::ObjectCoreExtensions#singleton_method_added

Defined in:
lib/chef/shell/ext.rb

#singleton_method_added(mname) ⇒ Object



132
133
134
135
136
137
138
139
140
141
142
143
# File 'lib/chef/shell/ext.rb', line 132

def singleton_method_added(mname)
  if @desc
    help_descriptions << Help.new(mname.to_s, @desc.to_s, @explain)
    @desc, @explain = nil, nil
  end
  if @subcommand_help
    @subcommand_help.each do |subcommand, text|
      help_descriptions << Help.new("#{mname}.#{subcommand}", text.to_s, nil)
    end
  end
  @subcommand_help = {}
end