From 400b91ab02428c6a51886f31cbb12b9d4852b6e9 Mon Sep 17 00:00:00 2001 From: nfagerlund Date: Wed, 17 Aug 2011 15:20:26 -0700 Subject: Docs: Correct indentation of markdown code examples Code examples in several function doc strings were only indented by two spaces, which would not result in proper display when rendered as HTML. This commit corrects the indentation to four spaces. --- lib/puppet/parser/functions/getvar.rb | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'lib/puppet/parser/functions/getvar.rb') diff --git a/lib/puppet/parser/functions/getvar.rb b/lib/puppet/parser/functions/getvar.rb index ffd774d..3ca179f 100644 --- a/lib/puppet/parser/functions/getvar.rb +++ b/lib/puppet/parser/functions/getvar.rb @@ -5,11 +5,11 @@ module Puppet::Parser::Functions For example: - $foo = getvar('site::data::foo') + $foo = getvar('site::data::foo') This is useful if the namespace itself is stored in a string: - $bar = getvar("${datalocation}::bar") + $bar = getvar("${datalocation}::bar") ENDHEREDOC unless args.length == 1 -- cgit v1.2.3 From 4b5dfcc733cf5c56095313fcb16e155886ac9b4d Mon Sep 17 00:00:00 2001 From: nfagerlund Date: Wed, 17 Aug 2011 15:53:27 -0700 Subject: Docs: Copyedit function doc strings This commit makes several minor consistency and wording edits to the doc strings of the stdlib functions. --- lib/puppet/parser/functions/getvar.rb | 3 +++ 1 file changed, 3 insertions(+) (limited to 'lib/puppet/parser/functions/getvar.rb') diff --git a/lib/puppet/parser/functions/getvar.rb b/lib/puppet/parser/functions/getvar.rb index 3ca179f..1621149 100644 --- a/lib/puppet/parser/functions/getvar.rb +++ b/lib/puppet/parser/functions/getvar.rb @@ -6,10 +6,13 @@ module Puppet::Parser::Functions For example: $foo = getvar('site::data::foo') + # Equivalent to $foo = $site::data::foo This is useful if the namespace itself is stored in a string: + $datalocation = 'site::data' $bar = getvar("${datalocation}::bar") + # Equivalent to $bar = $site::data::bar ENDHEREDOC unless args.length == 1 -- cgit v1.2.3