]> git.openstreetmap.org Git - chef.git/blob - cookbooks/chef/libraries/edit_file.rb
supybot: fix git branches to follow
[chef.git] / cookbooks / chef / libraries / edit_file.rb
1 class Chef
2   module Mixin
3     module EditFile
4       def edit_file(file, &_block)
5         Chef::DelayedEvaluator.new do
6           ::File.new(file).collect do |line|
7             yield line
8           end.join("")
9         end
10       end
11     end
12   end
13
14   class Recipe
15     include Chef::Mixin::EditFile
16   end
17 end