Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Active profile ignored by maven-release-plugin in multi-module build

I have a multi-module maven build that requires a profile to be activated only on demand using the -P flag. But for some reason it is being ignored when doing a release using the maven-release-plugin.

The following command line activates the profile correctly and disables the activeByDefault profile:

mvn clean deploy -Poracle

But when doing a release with the following command:

mvn help:active-profiles release:clean release:prepare release:perform -Poracle

...the profile is reported as being active by the active-profiles output but in fact only the activeByDefault profile is enabled.

Is this the expected behaviour or am I missing some maven magic?

like image 989
KevinS Avatar asked Jan 18 '26 09:01

KevinS


1 Answers

Problem solved. Profiles must be specified as a configuration parameter to the plugin.

like image 199
KevinS Avatar answered Jan 21 '26 07:01

KevinS



Donate For Us

If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!