You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@maven.apache.org by "Pat Podenski (JIRA)" <ji...@codehaus.org> on 2008/10/30 04:27:51 UTC

[jira] Created: (ARCHETYPE-219) Warning messages for properties in pom.xml files

Warning messages for properties in pom.xml files
------------------------------------------------

                 Key: ARCHETYPE-219
                 URL: http://jira.codehaus.org/browse/ARCHETYPE-219
             Project: Maven Archetype
          Issue Type: Bug
    Affects Versions: 2.0-alpha-4
         Environment: Windows or Mac OS X
Apache Maven 2.0.9
            Reporter: Pat Podenski
            Priority: Minor
         Attachments: foo-archetype.zip

Property expression in pom.xml are not escaped when creating an archetype from a project. As a result warning messages appear during project creation from the archetype.

I was able to eliminate the warning messages by escaping the property expressions. For example, in a pom.xml file, I added a #set for escaping '$' at the beginning of the pom.xml and then applied the escape to the property expression as shown below:

#set( $symbol_dollar = '$' )
<?xml version="1.0" encoding="UTF-8"?>
....
....
<directory>${symbol_dollar}{basedir}/src/main/resources</directory>

If the archetype plugin would detect these property expressions and provide the escaping, then it would not be necessary to go through each pom.xml (e.g., in a multimodule project) and hand edit the escapes for property expressions.

I am enclosing a simple multimodule project archetype in which I added the escape by hand editing the pom.xml of the sub module.



-- 
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

        

[jira] Commented: (ARCHETYPE-219) Warning messages for properties in pom.xml files

Posted by "Pat Podenski (JIRA)" <ji...@codehaus.org>.
    [ http://jira.codehaus.org/browse/ARCHETYPE-219?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=152381#action_152381 ] 

Pat Podenski commented on ARCHETYPE-219:
----------------------------------------

In the description above I failed to mention that for files other than the pom.xml files, the archetype already does the escaping as described above -- it just doesn't do the escape markup for pom.xml files.


> Warning messages for properties in pom.xml files
> ------------------------------------------------
>
>                 Key: ARCHETYPE-219
>                 URL: http://jira.codehaus.org/browse/ARCHETYPE-219
>             Project: Maven Archetype
>          Issue Type: Bug
>    Affects Versions: 2.0-alpha-4
>         Environment: Windows or Mac OS X
> Apache Maven 2.0.9
>            Reporter: Pat Podenski
>            Priority: Minor
>         Attachments: foo-archetype.zip
>
>
> Property expression in pom.xml are not escaped when creating an archetype from a project. As a result warning messages appear during project creation from the archetype.
> I was able to eliminate the warning messages by escaping the property expressions. For example, in a pom.xml file, I added a #set for escaping '$' at the beginning of the pom.xml and then applied the escape to the property expression as shown below:
> #set( $symbol_dollar = '$' )
> <?xml version="1.0" encoding="UTF-8"?>
> ....
> ....
> <directory>${symbol_dollar}{basedir}/src/main/resources</directory>
> If the archetype plugin would detect these property expressions and provide the escaping, then it would not be necessary to go through each pom.xml (e.g., in a multimodule project) and hand edit the escapes for property expressions.
> I am enclosing a simple multimodule project archetype in which I added the escape by hand editing the pom.xml of the sub module.

-- 
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