Skip to content

Instantly share code, notes, and snippets.

@kwilczynski
Created May 16, 2011 23:45
Show Gist options
  • Save kwilczynski/975609 to your computer and use it in GitHub Desktop.
Save kwilczynski/975609 to your computer and use it in GitHub Desktop.
Puppet DSL iterator via define ...
matti@acrux ~ $ cat - | puppet
$a = [ 'a', 'b', 'c' ]
define iterator { notice $name }
iterator { $a:; }
notice: Scope(Iterator[a]): a
notice: Scope(Iterator[b]): b
notice: Scope(Iterator[c]): c
matti@acrux ~ $
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment