Method: Chef::Util::FileEdit#search_file_replace

Defined in:
lib/chef/util/file_edit.rb

#search_file_replace(regex, replace) ⇒ Object

search the file line by line and match each line with the given regex if matched, replace the match (all occurances) with the replace parameter



48
49
50
# File 'lib/chef/util/file_edit.rb', line 48

def search_file_replace(regex, replace)
  search_match(regex, replace, 'r', 2)
end