Skip to content
Browse files

perlbrew recipe takes perls attribute to install

  • Loading branch information...
1 parent fed292c commit d47ea3dfe6ddf008019bb08a5964def9b88c1836 @xdg xdg committed Jan 6, 2012
Showing with 10 additions and 0 deletions.
  1. +1 −0 cookbooks/perlbrew/attributes/default.rb
  2. +9 −0 cookbooks/perlbrew/recipes/default.rb
View
1 cookbooks/perlbrew/attributes/default.rb
@@ -19,4 +19,5 @@
#
default['perlbrew']['perlbrew_root'] = '/opt/perlbrew'
+default['perlbrew']['perls'] = []
View
9 cookbooks/perlbrew/recipes/default.rb
@@ -46,3 +46,12 @@
EOC
not_if {::File.exists?(perlbrew_bin)}
end
+
+# were any perls requested in attributes?
+if node['perlbrew']['perls']
+ node['perlbrew']['perls'].each do |p|
+ perlbrew_perl p do
+ action :install
+ end
+ end
+end

0 comments on commit d47ea3d

Please sign in to comment.
Something went wrong with that request. Please try again.