You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@maven.apache.org by Karl Heinz Marbaise <kh...@gmx.de> on 2014/08/29 22:11:03 UTC

Re: Create multi-module archetype with one module only active in a profile

Hi,

a simple solution is to make such a module (sounds like an integration 
test module) just the profile inside the module so the execution of the 
integration tests is activated/deactivated by a profile things like 
maven-failsafe-plugin or whatever...

This prevent problems with releases etc.

Kind regards
Karl-Heinz Marbaise
On 8/29/14 9:15 PM, Thomas Larsson wrote:
> Thanks Karl,
>
> This seems like the sensible thing to do, and yes, we have already
> encountered the headache of keeping the submodules version number in
> sync after a release :-)
>
> Perhaps this should have been obvious. Thanks for the help anyway!
> /Thomas
>
>
> On Fri, Aug 29, 2014 at 8:28 PM, Karl Heinz Marbaise <khmarbaise@gmx.de
> <ma...@gmx.de>> wrote:
>
>     Hi,
>
>      >
>
>         I am trying to create an archetype with two modules, one main
>         and one itest.
>         I would like to have the itest module only active when run with
>         a profile.
>
>         In my original project, the root pom includes a part like this:
>
>               <profiles>
>                   <profile>
>                       <id>itest</id>
>                       <modules>
>                           <module>itest</module>
>                       </modules>
>                   </profile>
>               </profiles>
>
>         However, in the archetype-metadata.xml reference there is
>         nothing mentioned
>         about profiles.
>
>
>     First do never create a module which is included by a profile, cause
>     you will get trouble...
>
>     In particular if you do a release and afterwards doing a build and
>     activate the profile...
>     Take a deeper look
>     here:http://blog.soebes.de/__blog/2013/11/09/why-is-it-bad-__to-activate-slash-deactive-__modules-by-profiles-in-maven/
>     <http://blog.soebes.de/blog/2013/11/09/why-is-it-bad-to-activate-slash-deactive-modules-by-profiles-in-maven/>
>
>

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@maven.apache.org
For additional commands, e-mail: dev-help@maven.apache.org


Re: Create multi-module archetype with one module only active in a profile

Posted by Karl Heinz Marbaise <kh...@gmx.de>.
Hi sorry ...my fault ...wrong reply given...should have been on the 
users list...

Kind regards
Karl-Heinz Marbaise
On 8/29/14 10:11 PM, Karl Heinz Marbaise wrote:
> Hi,
>
> a simple solution is to make such a module (sounds like an integration
> test module) just the profile inside the module so the execution of the
> integration tests is activated/deactivated by a profile things like
> maven-failsafe-plugin or whatever...
>
> This prevent problems with releases etc.
>
> Kind regards
> Karl-Heinz Marbaise
> On 8/29/14 9:15 PM, Thomas Larsson wrote:
>> Thanks Karl,
>>
>> This seems like the sensible thing to do, and yes, we have already
>> encountered the headache of keeping the submodules version number in
>> sync after a release :-)
>>
>> Perhaps this should have been obvious. Thanks for the help anyway!
>> /Thomas
>>
>>
>> On Fri, Aug 29, 2014 at 8:28 PM, Karl Heinz Marbaise <khmarbaise@gmx.de
>> <ma...@gmx.de>> wrote:
>>
>>     Hi,
>>
>>      >
>>
>>         I am trying to create an archetype with two modules, one main
>>         and one itest.
>>         I would like to have the itest module only active when run with
>>         a profile.
>>
>>         In my original project, the root pom includes a part like this:
>>
>>               <profiles>
>>                   <profile>
>>                       <id>itest</id>
>>                       <modules>
>>                           <module>itest</module>
>>                       </modules>
>>                   </profile>
>>               </profiles>
>>
>>         However, in the archetype-metadata.xml reference there is
>>         nothing mentioned
>>         about profiles.
>>
>>
>>     First do never create a module which is included by a profile, cause
>>     you will get trouble...
>>
>>     In particular if you do a release and afterwards doing a build and
>>     activate the profile...
>>     Take a deeper look

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@maven.apache.org
For additional commands, e-mail: dev-help@maven.apache.org