diff options
| author | nfagerlund <nick.fagerlund@gmail.com> | 2011-08-09 17:33:14 -0700 |
|---|---|---|
| committer | nfagerlund <nick.fagerlund@gmail.com> | 2011-08-17 10:32:54 -0700 |
| commit | 7ac10930b30f13b5fdb7aea094283c8c122a0918 (patch) | |
| tree | f31de098035402cf400d47c8cd632ea418b5eef2 /lib | |
| parent | fe22c1c4819d035af02c9db5d065a712dc2d0e3c (diff) | |
| download | puppet-7ac10930b30f13b5fdb7aea094283c8c122a0918.tar.gz puppet-7ac10930b30f13b5fdb7aea094283c8c122a0918.tar.xz puppet-7ac10930b30f13b5fdb7aea094283c8c122a0918.zip | |
(#8037) Fix incorrect example in Augeas type reference
The changes attribute for the Augeas type's second example was
incorrect, as it had leading slashes that took the paths out of the
context of /files. This commit fixes the bad example, and changes the doc
string to a heredoc to eliminate some messy escaping.
Diffstat (limited to 'lib')
| -rw-r--r-- | lib/puppet/type/augeas.rb | 23 |
1 files changed, 12 insertions, 11 deletions
diff --git a/lib/puppet/type/augeas.rb b/lib/puppet/type/augeas.rb index f4d3c43e1..c96986e7e 100644 --- a/lib/puppet/type/augeas.rb +++ b/lib/puppet/type/augeas.rb @@ -20,7 +20,8 @@ Puppet::Type.newtype(:augeas) do feature :need_to_run?, "If the command should run" feature :execute_changes, "Actually make the changes" - @doc = "Apply the changes (single or array of changes) to the filesystem + @doc = <<-EOT + Apply the changes (single or array of changes) to the filesystem via the augeas tool. Requires: @@ -30,24 +31,24 @@ Puppet::Type.newtype(:augeas) do Sample usage with a string: - augeas{\"test1\" : - context => \"/files/etc/sysconfig/firstboot\", - changes => \"set RUN_FIRSTBOOT YES\", - onlyif => \"match other_value size > 0\", + augeas{"test1" : + context => "/files/etc/sysconfig/firstboot", + changes => "set RUN_FIRSTBOOT YES", + onlyif => "match other_value size > 0", } Sample usage with an array and custom lenses: - augeas{\"jboss_conf\": - context => \"/files\", + augeas{"jboss_conf": + context => "/files", changes => [ - \"set /etc/jbossas/jbossas.conf/JBOSS_IP $ipaddress\", - \"set /etc/jbossas/jbossas.conf/JAVA_HOME /usr\" + "set etc/jbossas/jbossas.conf/JBOSS_IP $ipaddress", + "set etc/jbossas/jbossas.conf/JAVA_HOME /usr", ], - load_path => \"$/usr/share/jbossas/lenses\", + load_path => "$/usr/share/jbossas/lenses", } - " + EOT newparam (:name) do desc "The name of this task. Used for uniqueness" |
