projects
/
mirror
/
dsa-puppet.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Update stdlib and concat to 6.1.0 both
[mirror/dsa-puppet.git]
/
3rdparty
/
modules
/
stdlib
/
lib
/
puppet
/
functions
/
to_yaml.rb
diff --git
a/3rdparty/modules/stdlib/lib/puppet/functions/to_yaml.rb
b/3rdparty/modules/stdlib/lib/puppet/functions/to_yaml.rb
index
fdd7370
..
d5fe259
100644
(file)
--- a/
3rdparty/modules/stdlib/lib/puppet/functions/to_yaml.rb
+++ b/
3rdparty/modules/stdlib/lib/puppet/functions/to_yaml.rb
@@
-1,4
+1,6
@@
-# Take a data structure and output it as YAML
+require 'yaml'
+# @summary
+# Convert a data structure and output it as YAML
#
# @example how to output YAML
# # output yaml to a file
#
# @example how to output YAML
# # output yaml to a file
@@
-6,11
+8,10
@@
# ensure => file,
# content => to_yaml($myhash),
# }
# ensure => file,
# content => to_yaml($myhash),
# }
-#
-#
-require 'yaml'
-
Puppet::Functions.create_function(:to_yaml) do
Puppet::Functions.create_function(:to_yaml) do
+ # @param data
+ #
+ # @return [String]
dispatch :to_yaml do
param 'Any', :data
end
dispatch :to_yaml do
param 'Any', :data
end