maven打包jar上传到nexus
生活随笔
收集整理的這篇文章主要介紹了
maven打包jar上传到nexus
小編覺得挺不錯的,現在分享給大家,幫大家做個參考.
2019獨角獸企業重金招聘Python工程師標準>>>
首先配置nexus
如果nexus返回400,那就是這里沒配好
pom.xml增加節點:
<distributionManagement><repository><id>nexus-3rd</id><url>http://192.168.0.231:8081/nexus/content/repositories/thirdparty/</url></repository> </distributionManagement>plugins增加節點上傳源碼包
<plugin><groupId>org.apache.maven.plugins</groupId><artifactId>maven-source-plugin</artifactId><executions><execution><id>attach-sources</id><goals><goal>jar</goal></goals></execution></executions> </plugin>在setting中設置:
? <server>
? ?<username>admin</username>???????
? ?<password>123456</password>??????????
? ?<id>nexus-3rd</id>
? </server>
?
?
最后執行,? 意味跳過單元測試: -Dmaven.test.skip=true
mvn deploy -Dmaven.test.skip=true
?
轉載于:https://my.oschina.net/u/2271162/blog/869329
總結
以上是生活随笔為你收集整理的maven打包jar上传到nexus的全部內容,希望文章能夠幫你解決所遇到的問題。
- 上一篇: Linux文件搜索
- 下一篇: iOS 通过Jenkins 自动构建ip