velocity-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From sebb <>
Subject Velocity generates lines with mixed EOL
Date Wed, 05 May 2010 14:40:41 GMT
I'm using Anakia/Velocity 1.6.2 to render XML as HTML on Win/XP.

The input XML all has CRLF line endings, but the generated HTML has
some lines that end with LF only. [This causes SVN checkin to fail]

The code that causes the problem is as follows:

#foreach ($rl_node in $itemToLoop.getContent())

If the text has CRLF in the input, then it ends up with just LF in the output.


<tag>inline text</tag>

is handled OK, but

more text

generates output with LF line endings.

The same problem occurs when using the Maven changes plugin to
generate an announcement script - the text content of the <action> tag
has CR stripped on output.

Note that most of the output lines generated by Velocity have the
correct CRLF line-end on Windows. It is only text that was read from a
tag and re-output by Velocity that has the problem.

Seems to me that this might be a bug in Velocity?

To unsubscribe, e-mail:
For additional commands, e-mail:

View raw message