You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@maven.apache.org by "John Casey (JIRA)" <ji...@codehaus.org> on 2008/10/28 21:58:51 UTC
[jira] Commented: (MNG-3807) Maven is not interpolatin Properties
at plugin configuration
[ http://jira.codehaus.org/browse/MNG-3807?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=152198#action_152198 ]
John Casey commented on MNG-3807:
---------------------------------
This is related to the version of the plexus container we're using in maven. With more recent versions, the PropertiesConverter (used to convert XML to a Properties instance for plugin parameter injection) does evaluate embedded expressions. However, as of 1.0-alpha-9 of the plexus container, this new code was not in place.
It seems we have two options for fixing this:
1. create a maintenance branch based on plexus 1.0-alpha-9 and fix the PropertiesConverter there, then release a new revision for use in maven
2. move maven onto a more recent plexus version, which will entail quite a bit of work since the component model has changed in important ways since alpha-9.
My personal opinion is that #2 is preferable if it's reasonably easy to do (not sure on this). This would modernize Maven WRT the plexus container, and enable us to track a little more closely with the progress in plexus in future. However, we could fix the PropertiesConverter itself very quickly, making #1 a much more expedient option.
> Maven is not interpolatin Properties at plugin configuration
> ------------------------------------------------------------
>
> Key: MNG-3807
> URL: http://jira.codehaus.org/browse/MNG-3807
> Project: Maven 2
> Issue Type: Bug
> Components: Inheritance and Interpolation
> Affects Versions: 2.0.9, 2.1.0-M1
> Reporter: Marvin Froeder
> Fix For: 2.1.0-M2
>
>
> My plugin has a configuration like this:
> {noformat}
> /**
> * My Properties.
> *
> * @parameter
> */
> private Properties myProperties;
> {noformat}
> When I configure like this:
> {noformat}
> <myProperties>
> <property>
> <name>propertyName1</name>
> <value>${buildnumber}</value> <!-- property injected on maven properties by http://mojo.codehaus.org/buildnumber-maven-plugin/ -->
> <property>
> </myProperties>
> {noformat}
> Maven doesn't interpolate the buildnumber. But the value is available at project.getProperties().
--
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