next up previous contents index
Next: Examples Up: ReplaceRegExp Previous: Description   Contents   Index

Parameters

Attribute Description Required
file file for which the regular expression should be replaced. Yes if no nested <fileset> is used
match The regular expression pattern to match in the file(s) Yes, if no nested <regexp> is used
replace The substitution pattern to place in the file(s) in place of the regular expression. Yes, if no nested <substitution> is used
flags The flags to use when matching the regular expression. For more information, consult the Perl5 syntax g : Global replacement. Replace all occurences found i : Case Insensitive. Do not consider case in the match m : Multiline. Treat the string as multiple lines of input, using "caret" and "$" as the start or end of any line, respectively, rather than start or end of string. s : Singleline. Treat the string as a single line of input, using "." to match any character, including a newline, which normally, it would not match. No
byline Process the file(s) one line at a time, executing the replacement on one line at a time (true/false). This is useful if you want to only replace the first occurence of a regular expression on each line, which is not easy to do when processing the file as a whole. Defaults to false. No


next up previous contents index
Next: Examples Up: ReplaceRegExp Previous: Description   Contents   Index
Andrew Marlow 2003-07-08