From e9d4c9ae828688f8a1ea53116e165836e3245ea2 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Jan=20Mat=C3=A8rne?= ${src}/build.properties
<replaceregexp byline="true"> @@ -141,6 +144,7 @@ value, in the file${src}/build.properties
with "NewProperty" in a properties file, preserving the existing value, in all files ending in.properties
in the current directory +
<replaceregexp match="\s+" replace=" " flags="g" byline="true"> <fileset dir="${html.dir}" includes="**/*.html"/> @@ -148,7 +152,6 @@ value, in all files ending in.properties
in the current directory<replaces all whitespaces (blanks, tabs, etc) by one blank remaining the line separator. So with input -
would converted to +<html> <body> @@ -156,13 +159,47 @@ line separator. So with input <<TAB>> </body></html>+ + +<html> <body> <h1> T E S T </h1> </body></html>+
+++<replaceregexp match="\\n" replace="${line.separator}" flags="g" byline="true"> + <fileset dir="${dir}"/> +</replaceregexp> +replaces all \n markers (beware the quoting of the backslash) by a line break. +So with input +
++would converted to ++one\ntwo\nthree +++Beware that inserting line breaks could break file syntax. For example in xml: ++one +two +three +++++<root> + <text>line breaks \n should work in text</text> + <attribute value="but breaks \n attributes" /> +</root> ++