[Pkg-puppet-devel] [SCM] Puppet packaging for Debian branch, upstream, updated. 2.6.1rc1-141-gcdb2b90

markus (none) markus at AVA-351181.
Mon Aug 16 12:48:50 UTC 2010


The following commit has been merged in the upstream branch:
commit 539b57c1f119be60c774db183dcaec37b1fd5cd5
Author: Jesse Wolfe <jes5199 at gmail.com>
Date:   Tue Jul 27 15:30:46 2010 -0700

    [#4347] run_mode was colliding with --mode for "puppet doc"
    
    The run_mode value was incorrectly getting stored to Puppet[:mode], which
    was confusing the optparser for applications that declare a --mode
    parameter.

diff --git a/lib/puppet/application.rb b/lib/puppet/application.rb
index 0a8fbc1..2fec38b 100644
--- a/lib/puppet/application.rb
+++ b/lib/puppet/application.rb
@@ -285,7 +285,7 @@ class Application
       Puppet.settings.set_value(:name, Puppet.application_name.to_s, :mutable_defaults)
       Puppet.settings.set_value(:logdir, Puppet.run_mode.logopts, :mutable_defaults)
       Puppet.settings.set_value(:rundir, Puppet.run_mode.run_dir, :mutable_defaults)
-      Puppet.settings.set_value(:mode, Puppet.run_mode.name.to_s, :mutable_defaults)
+      Puppet.settings.set_value(:run_mode, Puppet.run_mode.name.to_s, :mutable_defaults)
     end
 
     require 'puppet'
diff --git a/lib/puppet/defaults.rb b/lib/puppet/defaults.rb
index 4b8004a..1c5ca53 100644
--- a/lib/puppet/defaults.rb
+++ b/lib/puppet/defaults.rb
@@ -7,7 +7,7 @@ module Puppet
     :vardir => [Puppet.run_mode.var_dir, "Where Puppet stores dynamic and growing data.  The default for this parameter is calculated specially, like `confdir`_."],
     :name => [Puppet.application_name.to_s, "The name of the application, if we are running as one.  The
       default is essentially $0 without the path or ``.rb``."],
-    :mode => [Puppet.run_mode.name.to_s, "The effective 'run mode' of the application: master, agent, or user."]
+    :run_mode => [Puppet.run_mode.name.to_s, "The effective 'run mode' of the application: master, agent, or user."]
   )
 
   setdefaults(:main, :logdir => Puppet.run_mode.logopts)

-- 
Puppet packaging for Debian



More information about the Pkg-puppet-devel mailing list