Skip to content

Commit

Permalink
Display valid generator types with --help output
Browse files Browse the repository at this point in the history
  • Loading branch information
drbrain committed Dec 3, 2008
1 parent 735ede7 commit d3a90ab
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion lib/rdoc/options.rb
Original file line number Diff line number Diff line change
Expand Up @@ -327,8 +327,10 @@ def parse(argv)

opt.separator nil

generator_text = @generators.keys.map { |name| " #{name}" }.sort

opt.on("--fmt=FORMAT", "--format=FORMAT", "-f", @generators.keys,
"Set the output formatter.") do |value|
"Set the output formatter. One of:", *generator_text) do |value|
@generator_name = value.downcase
setup_generator
end
Expand Down

0 comments on commit d3a90ab

Please sign in to comment.