Am 02/26/16 um 12:04 schrieb Arnaud Héritier:
> Hi Christian,
> 
>   Isn't it possible to add some tests here ?
>   Also something I'm not sure to understand in the case is if the user has
> another profile activated
>   AFAIR activeByDefault activates a profile only if no profile is manually
> activated (with activeProfiles or -P).
>   There is often a big misunderstanding with this option.

I asked the reporter to test the snapshot. See the last comment on
MNG-5984. Will add tests when everything is sorted out, of course.

> activeByDefault activates a profile only if no profile is
> manually activated (with activeProfiles or -P)

Looking at DefaultProfileSelector [1], that only applies to profiles
declared in the pom "Profile.SOURCE_POM.equals( profile.getSource() )".
Profiles from settings are handled differently. Currently the settings
are processed before any command line options (like -P, for example). I
think that needs to be changed so that the -P command line option also
works for profiles from settings. The commit is not only about handling
the "activeByDefault" case. The "<activations>" were ignored before as well.

[1]
<https://git-wip-us.apache.org/repos/asf?p=maven.git;a=blob;f=maven-model-builder/src/main/java/org/apache/maven/model/profile/DefaultProfileSelector.java;h=457ab2a3c1ebb350ae44efdab91b62bbc9512859;hb=HEAD>


---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to