summaryrefslogtreecommitdiffstats
path: root/lib/puppet/reference
diff options
context:
space:
mode:
Diffstat (limited to 'lib/puppet/reference')
-rw-r--r--lib/puppet/reference/configuration.rb4
-rw-r--r--lib/puppet/reference/metaparameter.rb4
-rw-r--r--lib/puppet/reference/providers.rb18
-rw-r--r--lib/puppet/reference/type.rb4
4 files changed, 15 insertions, 15 deletions
diff --git a/lib/puppet/reference/configuration.rb b/lib/puppet/reference/configuration.rb
index 352116cd5..2f60ecc65 100644
--- a/lib/puppet/reference/configuration.rb
+++ b/lib/puppet/reference/configuration.rb
@@ -31,9 +31,9 @@ config = Puppet::Util::Reference.newreference(:configuration, :depth => 1, :doc
end
# Leave out the section information; it was apparently confusing people.
- #str += "- **Section**: %s\n" % object.section
+ #str += "- **Section**: #{object.section}\n"
unless val == ""
- str += "- **Default**: %s\n" % val
+ str += "- **Default**: #{val}\n"
end
str += "\n"
end
diff --git a/lib/puppet/reference/metaparameter.rb b/lib/puppet/reference/metaparameter.rb
index 8e0a89ac6..9368de186 100644
--- a/lib/puppet/reference/metaparameter.rb
+++ b/lib/puppet/reference/metaparameter.rb
@@ -29,7 +29,7 @@ metaparameter = Puppet::Util::Reference.newreference :metaparameter, :doc => "Al
a.to_s <=> b.to_s
}.each { |param|
str += paramwrap(param.to_s, scrub(Puppet::Type.metaparamdoc(param)), :level => 4)
- #puts "<dt>" + param.to_s + "</dt>"
+ #puts "<dt>#{param}</dt>"
#puts tab(1) + Puppet::Type.metaparamdoc(param).scrub.indent($tab)gsub(/\n\s*/,' ')
#puts "<dd>"
#puts indent(scrub(Puppet::Type.metaparamdoc(param)), $tab)
@@ -40,7 +40,7 @@ metaparameter = Puppet::Util::Reference.newreference :metaparameter, :doc => "Al
}
rescue => detail
puts detail.backtrace
- puts "incorrect metaparams: %s" % detail
+ puts "incorrect metaparams: #{detail}"
exit(1)
end
diff --git a/lib/puppet/reference/providers.rb b/lib/puppet/reference/providers.rb
index 33d85061e..cc47876d6 100644
--- a/lib/puppet/reference/providers.rb
+++ b/lib/puppet/reference/providers.rb
@@ -53,31 +53,31 @@ providers = Puppet::Util::Reference.newreference :providers, :title => "Provider
suit = true
functional = true
else
- data << "[%s]_" % [count] # A pointer to the appropriate footnote
+ data << "[#{count}]_" # A pointer to the appropriate footnote
suit = false
end
# Add a footnote with the details about why this provider is unsuitable, if that's the case
unless suit
- details = ".. [%s]\n" % count
+ details = ".. [#{count}]\n"
missing.each do |test, values|
case test
when :exists
- details += " - Missing files %s\n" % values.join(", ")
+ details += " - Missing files #{values.join(", ")}\n"
when :variable
values.each do |name, facts|
if Puppet.settings.valid?(name)
- details += " - Setting %s (currently %s) not in list %s\n" % [name, Puppet.settings.value(name).inspect, facts.join(", ")]
+ details += " - Setting #{name} (currently #{Puppet.settings.value(name).inspect}) not in list #{facts.join(", ")}\n"
else
- details += " - Fact %s (currently %s) not in list %s\n" % [name, Facter.value(name).inspect, facts.join(", ")]
+ details += " - Fact #{name} (currently #{Facter.value(name).inspect}) not in list #{facts.join(", ")}\n"
end
end
when :true
- details += " - Got %s true tests that should have been false\n" % values
+ details += " - Got #{values} true tests that should have been false\n"
when :false
- details += " - Got %s false tests that should have been true\n" % values
+ details += " - Got #{values} false tests that should have been true\n"
when :feature
- details += " - Missing features %s\n" % values.collect { |f| f.to_s }.join(",")
+ details += " - Missing features #{values.collect { |f| f.to_s }.join(",")}\n"
end
end
notes << details
@@ -97,7 +97,7 @@ providers = Puppet::Util::Reference.newreference :providers, :title => "Provider
ret += h(type.name.to_s + "_", 2)
- ret += ".. _%s: %s\n\n" % [type.name, "http://reductivelabs.com/trac/puppet/wiki/TypeReference#%s" % type.name]
+ ret += ".. _#{type.name}: #{"http://reductivelabs.com/trac/puppet/wiki/TypeReference##{type.name}"}\n\n"
ret += option("Default provider", default)
ret += doctable(headers, table_data)
diff --git a/lib/puppet/reference/type.rb b/lib/puppet/reference/type.rb
index c18681c1f..6bd8be835 100644
--- a/lib/puppet/reference/type.rb
+++ b/lib/puppet/reference/type.rb
@@ -79,12 +79,12 @@ type = Puppet::Util::Reference.newreference :type, :doc => "All Puppet resource
property = type.propertybyname(sname)
unless property
- raise "Could not retrieve property %s on type %s" % [sname, type.name]
+ raise "Could not retrieve property #{sname} on type #{type.name}"
end
doc = nil
unless doc = property.doc
- $stderr.puts "No docs for %s[%s]" % [type, sname]
+ $stderr.puts "No docs for #{type}[#{sname}]"
next
end
doc = doc.dup