[
http://jira.codehaus.org/browse/DOXIASITETOOLS-39?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=231583#action_231583
]
Lukas Theussl commented on DOXIASITETOOLS-39:
---------------------------------------------
Stefan, I appreciate your efforts and feedback in spite the fact you are not
even affected by the problem :) I am just trying to figure out whether we
should be concerned at all. It obviously works with the velocity version we are
using (1.5), so the question is whether it's worth upgrading? I can confirm
that with Velocity 1.7-beta1 I get your error message, but not with any other
version. I also noted that the following works with any version:
{noformat}
#set ( $documentHeader = '<?xml version="1.0" encoding="UTF-8"?>' )
{noformat}
ie single quotes outside and no escaping of double quotes. That seems like the
most logical alternative for me. But then again, if things change with every
new version of velocity, then I am reluctant to upgrade anyway if there is no
other good reason...
> Velocity > 1.5 can't parse default-site.vm
> ------------------------------------------
>
> Key: DOXIASITETOOLS-39
> URL: http://jira.codehaus.org/browse/DOXIASITETOOLS-39
> Project: Maven Doxia Sitetools
> Issue Type: Improvement
> Components: Doc renderer, Site renderer
> Affects Versions: 1.0, 1.1
> Reporter: Stefan Bodewig
> Priority: Minor
>
> This is an issue detected by Gump which runs Maven builds but replaces
> dependencies with the trunk versions of things built by Gump rather than the
> version a project asks for.
> The Cargo build - see
> http://gump.zones.apache.org/gump/test/cargo/cargo/gump_work/build_cargo_cargo.html
> - fails because Velocity doesn't like the line
> #set ( $documentHeader = "<?xml version=\"1.0\" encoding=\"UTF-8\"?>" )
> because \" is not an escape sequence for Velocity (anymore?).
> I've taken this to the velocity list -
> http://mail-archives.apache.org/mod_mbox/velocity-dev/201008.mbox/%[email protected]%3e
> - and received the feedback that backslash
> escaping was not supported - and likely never has been - and you should
> either use single
> quotes inside the double quotes or use something like
> #set( $Q = '"' )
> #set ( $documentHeader = "<?xml version=" + $Q + "1.0" + $Q + ...
> I realize that it probably works for you right now using Velocity 1.5, that's
> why I used Improvement rather than bug as category. Still it may be worth to
> find a solution that works for the version of Velocity you want to use as
> well as future versions.
--
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators:
http://jira.codehaus.org/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira