diff options
author | Jacob Helwig <jacob@puppetlabs.com> | 2011-07-12 14:14:13 -0700 |
---|---|---|
committer | Jacob Helwig <jacob@puppetlabs.com> | 2011-08-19 13:48:29 -0700 |
commit | a4378128c214d3c8c349a8052f018c13417b7cb1 (patch) | |
tree | 170e2651755cba1f684a95adef982f8071b14943 /lib | |
parent | af2446ad8ebf0c112901ea26efa37b06247c08b0 (diff) | |
download | puppet-a4378128c214d3c8c349a8052f018c13417b7cb1.tar.gz puppet-a4378128c214d3c8c349a8052f018c13417b7cb1.tar.xz puppet-a4378128c214d3c8c349a8052f018c13417b7cb1.zip |
(#8356) Specify setting type for color
Because we default the color setting to "false" on Microsoft Windows,
the heuristics used to detect which type of setting we're using were
getting confused, and mis-detected color as being a BooleanSetting
rather than just a Setting.
By specifying that color is a "Setting", we can skip the
auto-detection, and avoid this problem entirely.
Reviewed-by: Josh Cooper <josh@puppetlabs.com>
(cherry picked from commit b84bdbf31bbb0c5d5501bf6f32a9c0d0dc6acc94)
Diffstat (limited to 'lib')
-rw-r--r-- | lib/puppet/defaults.rb | 8 |
1 files changed, 6 insertions, 2 deletions
diff --git a/lib/puppet/defaults.rb b/lib/puppet/defaults.rb index 85626b2f9..b9859b03b 100644 --- a/lib/puppet/defaults.rb +++ b/lib/puppet/defaults.rb @@ -47,10 +47,14 @@ module Puppet exits. Comma-separate multiple values. For a list of all values, specify 'all'. This feature is only available in Puppet versions higher than 0.18.4."], - :color => [(Puppet.features.microsoft_windows? ? "false" : "ansi"), "Whether to use colors when logging to the console. + :color => { + :default => (Puppet.features.microsoft_windows? ? "false" : "ansi"), + :type => :setting, + :desc => "Whether to use colors when logging to the console. Valid values are `ansi` (equivalent to `true`), `html` (mostly used during testing with TextMate), and `false`, which produces - no color."], + no color.", + }, :mkusers => [false, "Whether to create the necessary user and group that puppet agent will run as."], |