[RNG] Aggregate artefacts (for archive download)

classic Classic list List threaded Threaded
5 messages Options
Reply | Threaded
Open this post in threaded view
|

[RNG] Aggregate artefacts (for archive download)

Gilles Sadowski
Hello.


AFAIU, a multi-module project creates separate artefacts for each
module.
This is all fine but for the case when one wants to download them
from the web site: a user would have to download each module
separately (from the "Download" link on the module's respective
page).

This is tedious since the most usual case is that more than one
artefact would be needed. (And certainly if one wants to build
from the "src" archives.)

How can I generate the "parent" artefacts
   commons-rng-1.0-bin.tar.gz
   commons-rng-1.0-src.tar.gz
   ... (idem for ".zip" etc.)
so that they contain the artefacts of _all_ the modules?


Thanks,
Gilles


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

Reply | Threaded
Open this post in threaded view
|

Re: [RNG] Aggregate artefacts (for archive download)

garydgregory
You use the assembly plugin.

mvn assembly:single

Gary

On Nov 23, 2016 8:45 AM, "Gilles" <[hidden email]> wrote:

> Hello.
>
>
> AFAIU, a multi-module project creates separate artefacts for each
> module.
> This is all fine but for the case when one wants to download them
> from the web site: a user would have to download each module
> separately (from the "Download" link on the module's respective
> page).
>
> This is tedious since the most usual case is that more than one
> artefact would be needed. (And certainly if one wants to build
> from the "src" archives.)
>
> How can I generate the "parent" artefacts
>   commons-rng-1.0-bin.tar.gz
>   commons-rng-1.0-src.tar.gz
>   ... (idem for ".zip" etc.)
> so that they contain the artefacts of _all_ the modules?
>
>
> Thanks,
> Gilles
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: [hidden email]
> For additional commands, e-mail: [hidden email]
>
>
Reply | Threaded
Open this post in threaded view
|

Re: [RNG] Aggregate artefacts (for archive download)

Gilles Sadowski
On Wed, 23 Nov 2016 09:12:33 -0800, Gary Gregory wrote:
> You use the assembly plugin.
>
> mvn assembly:single
>

After running
  $ mvn clean deploy assembly:single -Prelease -Ptest-deploy

There is no single archive file containing all the distribution.
[Neither in "target", nor in "targer/deploy".]

Shouldn't something be added to
   src/assembly/src.xml
   src/assembly/bin.xml
in order to achieve that goal?

Regards,
Gilles


> Gary
>
> On Nov 23, 2016 8:45 AM, "Gilles" <[hidden email]>
> wrote:
>
>> Hello.
>>
>>
>> AFAIU, a multi-module project creates separate artefacts for each
>> module.
>> This is all fine but for the case when one wants to download them
>> from the web site: a user would have to download each module
>> separately (from the "Download" link on the module's respective
>> page).
>>
>> This is tedious since the most usual case is that more than one
>> artefact would be needed. (And certainly if one wants to build
>> from the "src" archives.)
>>
>> How can I generate the "parent" artefacts
>>   commons-rng-1.0-bin.tar.gz
>>   commons-rng-1.0-src.tar.gz
>>   ... (idem for ".zip" etc.)
>> so that they contain the artefacts of _all_ the modules?
>>
>>
>> Thanks,
>> Gilles
>>
>>
>>
>> ---------------------------------------------------------------------
>> To unsubscribe, e-mail: [hidden email]
>> For additional commands, e-mail: [hidden email]
>>
>>


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

Reply | Threaded
Open this post in threaded view
|

Re: [RNG] Aggregate artefacts (for archive download)

Jörg Schaible-5
Gilles wrote:

> On Wed, 23 Nov 2016 09:12:33 -0800, Gary Gregory wrote:
>> You use the assembly plugin.
>>
>> mvn assembly:single
>>
>
> After running
>   $ mvn clean deploy assembly:single -Prelease -Ptest-deploy
>
> There is no single archive file containing all the distribution.
> [Neither in "target", nor in "targer/deploy".]
>
> Shouldn't something be added to
>    src/assembly/src.xml
>    src/assembly/bin.xml
> in order to achieve that goal?

That's what Gary meant. You have to add an execution for the assembly to the
parent pom and configure an own assembly descriptor. assembly:single does
not work from the command line.

Cheers,
Jörg



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

Reply | Threaded
Open this post in threaded view
|

Re: [RNG] Aggregate artefacts (for archive download)

Stian Soiland-Reyes
Within the assembly descriptor you can use a <moduleSet> for the modules
you want to include.

See
https://github.com/apache/commons-jcs/blob/trunk/commons-jcs-dist/src/assembly/bin.xml
for example, here the assembly is done in a -dist submodule itself, but it
can also be done directly in the parent as long as the assembly plugin is
configured to not run in submodules.

On 24 Nov 2016 8:01 am, "Jörg Schaible" <[hidden email]>
wrote:

> Gilles wrote:
>
> > On Wed, 23 Nov 2016 09:12:33 -0800, Gary Gregory wrote:
> >> You use the assembly plugin.
> >>
> >> mvn assembly:single
> >>
> >
> > After running
> >   $ mvn clean deploy assembly:single -Prelease -Ptest-deploy
> >
> > There is no single archive file containing all the distribution.
> > [Neither in "target", nor in "targer/deploy".]
> >
> > Shouldn't something be added to
> >    src/assembly/src.xml
> >    src/assembly/bin.xml
> > in order to achieve that goal?
>
> That's what Gary meant. You have to add an execution for the assembly to
> the
> parent pom and configure an own assembly descriptor. assembly:single does
> not work from the command line.
>
> Cheers,
> Jörg
>
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: [hidden email]
> For additional commands, e-mail: [hidden email]
>
>