Created
January 9, 2014 00:57
-
-
Save charleseff/8327591 to your computer and use it in GitHub Desktop.
Is there a better way to do this?
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
$attrs_first = { | |
command => "/foo", | |
} | |
if $condition { | |
$more_attrs = {require => Class['bar']} | |
$attrs = merge($attrs_first, $more_attrs) | |
} else { | |
$attrs = $attrs_first | |
} | |
$resource = { "something" => $attrs } | |
create_resources(exec, $resource) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
compare to ruby: