idea maven 安装及卸载本地jar包

安装:

1. 打开控制台,切换到maven安装的bin目录

2. 执行命令 mvn install:install-file -DgroupId=domain.group -DartifactId=ArtifactId -Dversion=1.0.0.1 -Dpackaging=jar -Dfile=c:\mypackage.jar

3. pom.xml 文件设置dependency

<dependency>
    <groupId>domain.group</groupId>
    <artifactId>ArtifactId</artifactId>
    <version>1.0.0.1</version>
</dependency>

卸载:

1.mvn dependency:purge-local-repository -DmanualInclude="domain.group:ArtifactId"

2.mvn dependency:purge-local-repository -DreResolve=false

posted on 2023-01-29 13:42  空明流光  阅读(1323)  评论(0编辑  收藏  举报

导航