[ http://jira.codehaus.org/browse/MNG-2206?page=comments#action_65662 ]
Olivier Lamy commented on MNG-2206: ----------------------------------- Sorry for bad explanation concerning this issue. I try again ;-). My pom contains : <plugin> <artifactId>maven-antrun-plugin</artifactId> <configuration> <tasks> <echo>${value}</echo> </tasks> </configuration> <executions> <execution> <phase>validate</phase> <configuration> <tasks> <echo>${value}</echo> </tasks> </configuration> <goals> <goal>run</goal> </goals> </execution> </executions> </plugin> My settings contains : - profile <id>dev</dev> <activeByDefault>true</activeByDefault> and in properties section of this profile <value>dev</value> - profile <id>snapshots</id> and in properties section of this profile <value>snapshots</value> + in settings <activeProfiles> <activeProfile>dev</activeProfile> <activeProfile>snapshots</activeProfile> </activeProfiles> running mvn validate or mvn validate -P snapshots always displays : [echo] dev. running mvn validate -Dvalue=foo displays well value : [echo] foo But this doesn't seems to works with the P commands to activate properties values stored in the settings for each profiles. My use case is the following : I need to store some databases passwords with different profiles (dev,integration, user test and production) and with profile activation with the cli -P, I expect to have a expression replacement. I hope it's a better explanation ? Olivier > bad properties interpolation with profiles > ------------------------------------------- > > Key: MNG-2206 > URL: http://jira.codehaus.org/browse/MNG-2206 > Project: Maven 2 > Type: Bug > Components: Inheritence and Interpolation > Versions: 2.0.3 > Environment: cygwin > Reporter: Olivier Lamy > Priority: Blocker > Attachments: pom.xml > > > create two profiles in your settings.xml > - id test with a property <test>dev</test> > - id snapshots with a property <test>snapshots</test> > <activeProfiles> > <activeProfile>dev</activeProfile> > <activeProfile>snapshots</activeProfile> > </activeProfiles> > With the attached pom run : > mvn validate : > [echo] dev > mvn -P snapshots validate : > [echo] dev > Olivier -- 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