You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@maven.apache.org by "Natva, Arun Kumar" <ar...@bankofamerica.com> on 2016/03/24 20:37:54 UTC

build a maven artifact with a list of jars

Hi,
I have a list of jars (say around 100) and most of the applications developed in my team need these jars. I need to create a maven artifact using these jars and upload the artifact into my company's internal nexus repository so that other developers can simply add this artifact as a dependency in their projects.

I am looking for help over internet on how to do this, but did not find it so far. I cannot use maven-install-file plugin since it works only for one jar file. I am trying to experiment with maven-assembly-plugin & assembly descriptor, but haven't been successful.

A good example to accomplish the above would be really helpful. Can you please take a look at my problem and help me out with this.

Regards,
Arun,
Ph: (980)387-1766(w)

----------------------------------------------------------------------
This message, and any attachments, is for the intended recipient(s) only, may contain information that is privileged, confidential and/or proprietary and subject to important terms and conditions available at http://www.bankofamerica.com/emaildisclaimer.   If you are not the intended recipient, please delete this message.

Re: build a maven artifact with a list of jars

Posted by Ron Wheeler <rw...@artifact-software.com>.
Look at my articles at blog.artifact-software.com/tech on Maven

We do this as a normal way to work with Maven.

Ron
Ron

On 24/03/2016 3:37 PM, Natva, Arun Kumar wrote:
> Hi,
> I have a list of jars (say around 100) and most of the applications developed in my team need these jars. I need to create a maven artifact using these jars and upload the artifact into my company's internal nexus repository so that other developers can simply add this artifact as a dependency in their projects.
>
> I am looking for help over internet on how to do this, but did not find it so far. I cannot use maven-install-file plugin since it works only for one jar file. I am trying to experiment with maven-assembly-plugin & assembly descriptor, but haven't been successful.
>
> A good example to accomplish the above would be really helpful. Can you please take a look at my problem and help me out with this.
>
> Regards,
> Arun,
> Ph: (980)387-1766(w)
>
> ----------------------------------------------------------------------
> This message, and any attachments, is for the intended recipient(s) only, may contain information that is privileged, confidential and/or proprietary and subject to important terms and conditions available at http://www.bankofamerica.com/emaildisclaimer.   If you are not the intended recipient, please delete this message.
>


-- 
Ron Wheeler
President
Artifact Software Inc
email: rwheeler@artifact-software.com
skype: ronaldmwheeler
phone: 866-970-2435, ext 102


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


Re: build a maven artifact with a list of jars

Posted by Mark Eggers <it...@yahoo.com.INVALID>.
Arun,

What I've done in the past is to make a new project consisting of
nothing but dependencies with a packaging type of pom.

This is loaded into our local Nexus repository and referenced with a
dependency like the following:

<dependency>
<groupId>com.myCompany</groupId>
<artifactId>collection-of-jars</artifactId>
<version>1.0.0</version>
<type>pom</type>
</dependency>

This pulls in the required jars.

We use this to keep a collection of third party JARs together that must
be used together, but the vendor did not package them with Maven.

It would make sense to create a rational version number, as well as
document like crazy (especially if the JARs are a grab bag of dependencies).

Overriding this using exclusions becomes somewhat of a pain if the list
of dependencies is long. I'd favor a more modular approach and possibly
using archetypes / parent poms / DependencyManagement to deal with a
large list.

. . . just my (sleepy) 2 cents
/mde/

On 3/24/2016 12:37 PM, Natva, Arun Kumar wrote:
> Hi, I have a list of jars (say around 100) and most of the
> applications developed in my team need these jars. I need to create a
> maven artifact using these jars and upload the artifact into my
> company's internal nexus repository so that other developers can
> simply add this artifact as a dependency in their projects.
> 
> I am looking for help over internet on how to do this, but did not
> find it so far. I cannot use maven-install-file plugin since it works
> only for one jar file. I am trying to experiment with
> maven-assembly-plugin & assembly descriptor, but haven't been
> successful.
> 
> A good example to accomplish the above would be really helpful. Can
> you please take a look at my problem and help me out with this.
> 
> Regards, Arun, Ph: (980)387-1766(w)
> 
> ----------------------------------------------------------------------
>
> 
This message, and any attachments, is for the intended recipient(s)
only, may contain information that is privileged, confidential and/or
proprietary and subject to important terms and conditions available at
http://www.bankofamerica.com/emaildisclaimer.   If you are not the
intended recipient, please delete this message.
>