Maven: Install the jar to the local repository and the jar to the switch

Source: Internet
Author: User

http://blog.csdn.net/we_shell/article/details/49819221

MAVEN Configuration for Jar

<dependency>
<groupId>org.apache.thrift</groupId>
<artifactId>libthrift</artifactId>
<version>0.9.2</version>
</dependency>

1. Install the jar package to the local warehouse

Command:

[HTML]View PlainCopy
    1. MVN install:install-file -dfile=D:\thrift-0.9.2.jar -dgroupid=org.apache.thrift -dartifactid= libthrift -dversion=0.9.2 -dpackaging=jar



--DgroupId and DartifactId constitute the coordinates of the jar package in Pom.xml, corresponding to the DgroupId and DartifactId of the dependency
--Dfile indicates the absolute path of the jar package that needs to be uploaded
--Dpackaging for the type of installation file


2. Upload the jar to the

Command:

[HTML]View PlainCopy
    1. mvn deploy:deploy-file - Dgroupid=org.apache.thrift -dartifactid=libthrift -dversion=1.12 < span class= "attribute" >-dpackaging=jar -dfile=d:\thrift-0.9.2.jar -durl= Http://ip:port/nexus/content/repositories/thirdparty/ -drepositoryid=THIRDPARTY&NBSP;&NBSP;



--DgroupId and DartifactId constitute the coordinates of the jar package in Pom.xml, corresponding to the DgroupId and DartifactId of the dependency
--Dfile indicates the absolute path of the jar package that needs to be uploaded
--The URL address of the warehouse on Durl (open the Nexus left repositories menu, you can see the path)
--The representation ID of the DrepositoryId server, which can be seen in the Nexus configuration

Maven: Install the jar to the local repository and the jar to the switch

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.