Details
-
Bug
-
Resolution: Done
-
Minor
-
2.0.2
-
None
Description
See:
http://maven.apache.org/settings.html#Active_Profiles
On the command line (mvn), the element is evaluated as expected and the specified profiles are activated but when I load the very same pom.xml via Maven.resolver().offline().loadPomFromFile(...), the respective profiles are ignored, as it seems.
I came accross this issue when I wanted to override a property from pom.xml in settings.xml and ParsedPomFile.getProperties() kept returning the non-overriden value.
Notes:
- the following in settings.xml does work:
<activation> <activeByDefault>true</activeByDefault> </activation>
- a new property defined in a settings.xml profile also doesn't show up in ParsedPomFile.getProperties() which seems to prove that the profile is not actived