improved 'help' output
* sections separated by white space * plugin names are nicely formatted, e.g `Plugin: Exception Explorer v0.1.9`
This commit is contained in:
parent
1e49f38a1b
commit
4b53a97afa
|
@ -140,7 +140,9 @@ class Pry
|
|||
when %r{/pry/.*_commands/(.*).rb}
|
||||
$1.capitalize.gsub(/_/, " ")
|
||||
when %r{/(pry-[^\/]*)/}
|
||||
$1
|
||||
$1 =~ /pry-([\w_]+)-([\d\.]+)/
|
||||
name, version = $1, $2
|
||||
"Plugin: #{name.capitalize.gsub(/_/, " ")} v#{version}"
|
||||
when /pryrc/
|
||||
"~/.pryrc"
|
||||
else
|
||||
|
|
|
@ -363,7 +363,7 @@ class Pry
|
|||
end
|
||||
|
||||
unless commands.empty?
|
||||
help_text << "#{text.bold(key)}"
|
||||
help_text << "\n#{text.bold(key)}"
|
||||
help_text += commands.map do |command|
|
||||
" #{command.options[:listing].to_s.ljust(18)} #{command.description}"
|
||||
end
|
||||
|
|
Loading…
Reference in New Issue