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

Luke Kanies luke at puppetlabs.com
Tue May 10 08:05:28 UTC 2011


The following commit has been merged in the experimental branch:
commit 905ff3aee31775e3fff3ebf8a2eaa6bb2cf0f431
Author: Luke Kanies <luke at puppetlabs.com>
Date:   Sun Feb 27 16:34:10 2011 -0800

    Pretty-printing json using "jj"
    
    Signed-off-by: Luke Kanies <luke at puppetlabs.com>

diff --git a/lib/puppet/application/interface_base.rb b/lib/puppet/application/interface_base.rb
index 70022f1..d54ac79 100644
--- a/lib/puppet/application/interface_base.rb
+++ b/lib/puppet/application/interface_base.rb
@@ -52,7 +52,12 @@ class Puppet::Application::InterfaceBase < Puppet::Application
   # Override this if you need custom rendering.
   def render(result)
     render_method = Puppet::Network::FormatHandler.format(format).render_method
-    result.send(render_method)
+    if render_method == "to_pson"
+      jj result
+      exit(0)
+    else
+      result.send(render_method)
+    end
   end
 
   def setup

-- 
Puppet packaging for Debian



More information about the Pkg-puppet-devel mailing list