Details
-
Bug
-
Status: Closed
-
Major
-
Resolution: Duplicate
-
2.0.9
-
None
-
None
-
Windows XP Professional
Description
I created a profiles.xml file with three profiles in it as shown below. When I execute a Maven command like:
>mvn -f <path-to-basedir>\pom.xml -PconwebDev ...
the properties defined by profile conwebFinal are used. I shuffled the profiles around in the file and whichever one was defined last was the one whose values took effect. It seems as if all profiles are being activated and the last one wins.
When I put these same profiles in settings.xml or inside the main pom.xml, everything works properly.
Here are the profiles:
<profiles>
<!-- conweb Project-specific profiles -->
<profile>
<id>conwebDev</id>
<properties>
<app.properties>conweb.properties</app.properties>
<app.version.qualifier>DEV</app.version.qualifier>
</properties>
</profile>
<profile>
<id>conwebTest</id>
<properties>
<app.properties>conweb.properties</app.properties>
<app.version.qualifier>TEST</app.version.qualifier>
</properties>
</profile>
<profile>
<id>conwebFinal</id>
<properties>
<app.properties>conweb.properties</app.properties>
<app.version.qualifier>FINAL</app.version.qualifier>
</properties>
</profile>
</profiles>
Attachments
Issue Links
- duplicates
-
MNG-2605 Profiles in profiles.xml are active by default
- Closed