maven 私服上传jar
maven 私服上传jar
- 1. 手动上传
- 2. idea开发工具
1. 手动上传
- 上传私服
mvn deploy:deploy-file -DgroupId=com.example -DartifactId=my-jar -Dversion=1.0.0 -Dpackaging=jar -Dfile=/path/to/my-jar.jar -Durl=http://example.com/repository/mvn-release-private/ -DrepositoryId=my-repo
- 构建
如果已经构建一次并且失败,可能会缓存maven cache,此时需要搭配
-U属性一起使用,禁用maven cache
mvn clean package -U -Dmaven.test.skip=true
2. idea开发工具
mvn deploy
