I have a maven profile for skipping tests and license checks which looks the following way:
<profiles>
<profile>
<id>myProfile</id>
<properties>
<license.skip>true</license.skip>
<skipTests>true</skipTests>
</properties>
</profile>
</profiles>
The profile works like a charm and does what I want (skipping tests / license checks) when I launch it via:
mvn clean verify -PmyProfile
Now I want to add yet another system property to the profile which I can enable explicitly:
mvn clean verify -Dskip-validate-sources
However, when I try to add it to my profile:
<skip-validate-sources>true</skip-validate-sources>
or
<skip-validate-sources></skip-validate-sources>
It does not seem to work. Basically, this property enables another profile which is defined the following way:
<profile>
<id>validate-sources</id>
<activation>
<property>
<name>!skip-validate-sources</name>
</property>
</activation>
....
Any ideas how is it possible to define a system property which does not have value in a maven profile ?