Adding delete_lines

This commit is contained in:
Silvio Rhatto 2009-12-25 22:33:24 -02:00
parent 0f5508374a
commit a25d1e44c2

View file

@ -0,0 +1,5 @@
define delete_lines($file, $pattern) {
exec { "/bin/sed -i -r -e '/$pattern/d' $file":
onlyif => "/bin/grep -E '$pattern' '$file'",
}
}