summaryrefslogtreecommitdiffstats
path: root/lib/puppet/util
diff options
context:
space:
mode:
authorJames Turnbull <james@lovedthanlost.net>2009-09-22 13:24:31 +1000
committerJames Turnbull <james@lovedthanlost.net>2009-09-22 13:24:31 +1000
commitfd322daa42f751bfc6200b95e6151540b3eb541e (patch)
treeb58e0b5dc780c73c1f9ad236c6832806d019d09b /lib/puppet/util
parent6551e86a03f5fa1f499386c96faa4587bdfac24e (diff)
downloadpuppet-fd322daa42f751bfc6200b95e6151540b3eb541e.tar.gz
puppet-fd322daa42f751bfc6200b95e6151540b3eb541e.tar.xz
puppet-fd322daa42f751bfc6200b95e6151540b3eb541e.zip
Fixes #1538 - Fixes the yumrepo backtrace in noop mode.
Yumrepo type will now chmod on all files when a change happens. If the content is not changed then no chmod will occur.
Diffstat (limited to 'lib/puppet/util')
-rw-r--r--lib/puppet/util/inifile.rb8
1 files changed, 8 insertions, 0 deletions
diff --git a/lib/puppet/util/inifile.rb b/lib/puppet/util/inifile.rb
index 3c82f7d37..eb943fe13 100644
--- a/lib/puppet/util/inifile.rb
+++ b/lib/puppet/util/inifile.rb
@@ -180,6 +180,14 @@ module Puppet::Util::IniConfig
end
end
+ # Execute BLOCK, passing each file constituting this inifile
+ # as an argument
+ def each_file(&block)
+ @files.keys.each do |file|
+ yield(file)
+ end
+ end
+
# Return the Section with the given name or nil
def [](name)
name = name.to_s