1.进入存放jar目录,执行命令,安装jar
mvn install:install-file -Dfile=SourceCodeConstraint-1.0-SNAPSHOT.jar -DgroupId=com.yss.platform.tools -DartifactId=SourceCodeConstraint -Dversion=1.0-RELEASE -Dpackaging=jar
-DgroupId 和 -DartifactId 这两个参数与pom.xml中配置的内容相同.
2. pom.xml 添加依赖
<dependency>
<groupId>com.henghe.platform.tools</groupId>
<artifactId>SourceCodeConstraint</artifactId>
<version>1.0-RELEASE</version>
</dependency>