maven local warehouse jar package

maven打包本地
首先装mvn jdk对应版本
http://blog.csdn.net/chenxuejiakaren/article/details/7938524/
http://mirror.bit.edu.cn/apache/maven/maven-3/3.3.9/binaries/apache-maven-3.3.9-bin.zip
<dependency>
            <groupId>com.gexin</groupId>
            <artifactId>gexin-rp-sdk-base</artifactId>
            <version>4.0.0.2</version>
        </dependency>
        <dependency>
            <groupId>com.gexin</groupId>
            <artifactId>gexin-rp-sdk-http</artifactId>
            <version>4.0.0.2</version>
        </dependency>
        <dependency>
            <groupId>com.gexin</groupId>
            <artifactId>gexin-rp-sdk-template</artifactId>
            <version>4.0.0.2</version>
        </dependency>
start mvn install:install-file -DgroupId=com.gexin  -DartifactId=gexin-rp-sdk-base -Dversion=4.0.0.2 -Dpackaging=jar -Dfile=D:\Workarea\employeeBenefits-interface\data\gexin-rp-sdk-base-4.0.0.2.jar
start mvn install:install-file -DgroupId=com.gexin  -DartifactId=gexin-rp-sdk-http -Dversion=4.0.0.2 -Dpackaging=jar -Dfile=D:\Workarea\employeeBenefits-interface\data\gexin-rp-sdk-http-4.0.0.2.jar
start mvn install:install-file -DgroupId=com.gexin  -DartifactId=gexin-rp-sdk-template -Dversion=4.0.0.2 -Dpackaging=jar -Dfile=D:\Workarea\employeeBenefits-interface\data\gexin-rp-sdk-template-4.0.0.2.jar
http://www.tuicool.com/articles/RRzU3e
http://www.tuicool.com/articles/RRzU3e ok
to be used directly locally, the network needs to be installed
3. Unable to transfer from the remote warehouse to the local warehouse, the problem of unsuccessful jar package download, the specific error is as follows: ArtifactDescriptorException: Failed to read artifact descriptor for org.hibernate:hibernate-annotations:jar:3.5.6-Final:

At this time, there are a lot of red crosses in the maven project. It is really tangled, and problems follow one after another. . .

Solution:

First, right-click the project, run and execute the maven install command to download the dependent jar package from the remote warehouse to the local warehouse.
After the download is complete, right-click the project jpa-test--"Maven---"Update Project ---"Select Force Update of...---"ok

At this time, the red crosses of the refresh project are all gone, and the jar package is successfully imported.

Guess you like

Origin http://10.200.1.11:23101/article/api/json?id=326757335&siteId=291194637