Method not available on this version
This method is only available on newer versions.
The first available version (v2_6_3) is shown here.
display_klasses(with_modules = false, show_internal = false, klasses = Bundler::Thor::Base.subclasses)
private
Display information about the given klasses. If with_module is given, it
shows a table with information extracted from the yaml file.
# File lib/bundler/vendor/thor/lib/thor/runner.rb, line 278
def display_klasses(with_modules = false, show_internal = false, klasses = Bundler::Thor::Base.subclasses)
klasses -= [Bundler::Thor, Bundler::Thor::Runner, Bundler::Thor::Group] unless show_internal
raise Error, "No Bundler::Thor commands available" if klasses.empty?
show_modules if with_modules && !thor_yaml.empty?
list = Hash.new { |h, k| h[k] = [] }
groups = klasses.select { |k| k.ancestors.include?(Bundler::Thor::Group) }
# Get classes which inherit from Bundler::Thor
(klasses - groups).each { |k| list[k.namespace.split(":").first] += k.printable_commands(false) }
# Get classes which inherit from Bundler::Thor::Base
groups.map! { |k| k.printable_commands(false).first }
list["root"] = groups
# Order namespaces with default coming first
list = list.sort { |a, b| a[0].sub(/^default/, "") <=> b[0].sub(/^default/, "") }
list.each { |n, commands| display_commands(n, commands) unless commands.empty? }
end