1 Puppet::Type.newtype(:ini_setting) do
8 newparam(:name, :namevar => true) do
9 desc 'An arbitrary name used as the identity of the resource.'
13 desc 'The name of the section in the ini file in which the setting should be defined.' +
14 'If not provided, defaults to global, top of file, sections.'
19 desc 'The name of the setting to be defined.'
23 desc 'The ini file Puppet will ensure contains the specified setting.'
25 unless (Puppet.features.posix? and value =~ /^\//) or (Puppet.features.microsoft_windows? and (value =~ /^.:\// or value =~ /^\/\/[^\/]+\/[^\/]+/))
26 raise(Puppet::Error, "File paths must be fully qualified, not '#{value}'")
31 newparam(:key_val_separator) do
32 desc 'The separator string to use between each setting name and value. ' +
33 'Defaults to " = ", but you could use this to override e.g. ": ", or' +
34 'whether or not the separator should include whitespace.'
38 newproperty(:value) do
39 desc 'The value of the setting to be defined.'
42 newparam(:section_prefix) do
43 desc 'The prefix to the section name\'s header.' +
48 newparam(:section_suffix) do
49 desc 'The suffix to the section name\'s header.' +