On Mon, 18 Oct 2010 14:42:31 -0700, Rein Henrichs wrote: > > From: Paul Berry <[email protected]> > > RDoc.usage prints the usage string. As a result, `puts RDoc.usage` is > redundant > and unnecessary. > > See http://ruby-doc.org/core/classes/RDoc.html#M004706. > > Signed-off-by: Rein Henrichs <[email protected]> > --- > lib/facter/application.rb | 2 +- > 1 files changed, 1 insertions(+), 1 deletions(-) > > diff --git a/lib/facter/application.rb b/lib/facter/application.rb > index 9de9249..56827ec 100644 > --- a/lib/facter/application.rb > +++ b/lib/facter/application.rb > @@ -72,7 +72,7 @@ module Facter > begin > require 'rdoc/ri/ri_paths' > require 'rdoc/usage' > - puts RDoc.usage > + RDoc.usage # print usage and exit > rescue LoadError > $stderr.puts "No help available unless your RDoc has RDoc.usage" > exit(1) > -- > 1.7.0.4 >
+1, especially to the comment, explaining why there isn't a puts, or exit. -- Jacob Helwig
signature.asc
Description: Digital signature
