[Pkg-puppet-devel] [SCM] Puppet packaging for Debian branch, experimental, updated. debian/2.6.8-1-844-g7ec39d5

Matt Robinson matt at puppetlabs.com
Tue May 10 08:07:32 UTC 2011


The following commit has been merged in the experimental branch:
commit 7a4fcf2835ac414fe3c5b1b4e4b16c13a2c92d09
Author: Matt Robinson <matt at puppetlabs.com>
Date:   Tue Mar 22 22:48:17 2011 -0700

    (#6820) Fix RDOC parser to work with Ruby 1.9
    
    Lovely RDOC changed where it put everything in Ruby 1.9.  Now there's
    some conditional logic depending on Ruby version to determine which
    files to requrie. The tests still fail, but at least they run now.
    
    Reviewed-by: Jacob Helwig <jacob at puppetlabs.com>

diff --git a/lib/puppet/util/rdoc/parser.rb b/lib/puppet/util/rdoc/parser.rb
index 0f746e2..762ce25 100644
--- a/lib/puppet/util/rdoc/parser.rb
+++ b/lib/puppet/util/rdoc/parser.rb
@@ -7,13 +7,19 @@
 require "rdoc/code_objects"
 require "puppet/util/rdoc/code_objects"
 require "rdoc/tokenstream"
-require "rdoc/markup/simple_markup/preprocess"
-require "rdoc/parsers/parserfactory"
+
+if ::RUBY_VERSION =~ /1.9/
+	require "rdoc/markup/preprocess"
+	require "rdoc/parser"
+else
+	require "rdoc/markup/simple_markup/preprocess"
+	require "rdoc/parsers/parserfactory"
+end
 
 module RDoc
 
 class Parser
-  extend ParserFactory
+  extend ParserFactory unless ::RUBY_VERSION =~ /1.9/
 
   SITE = "__site__"
 

-- 
Puppet packaging for Debian



More information about the Pkg-puppet-devel mailing list