eclipse中maven插件上传项目jar包到私服
来源:互联网 发布:ping网络请求超时 编辑:程序博客网 时间:2024/04/28 19:56
我们知道,每个公司都会有自己的工具包或公共包,这种包就可以上传到公司的maven私服,就不用每个人都去同步开发包了。那么,怎么把本地项目打包并发布到私服呢?按照如下步骤就可以轻松完成。
1. 在setting.xml文件中增加如下内容:
<servers> <server> <!-- 发布的位置在POM中配置,以ID为关联,有很多公用的信息需要配置在POM文件里,最佳实践是定义一个公司级别的root pom --> <id>nexus</id> <username>admin</username> <password>admin123</password> </server> <server> <id>nexus-snapshots</id> <username>admin</username> <password>admin123</password> </server><server> <id>thirdparty</id> <username>admin</username> <password>admin123</password> </server> </servers>
2. 在项目的pom.xml文件中增加如下内容
<distributionManagement><repository> <id>nexus</id> <name>local private nexus</name> <url>http://192.168.xx.xx:8081/nexus/content/groups/public</url></repository><snapshotRepository> <id>nexus-snapshots</id> <name>local private nexus snapshots</name> <url>http://192.168.xx.xx:8081/nexus/content/groups/public-snapshots</url></snapshotRepository> </distributionManagement>
<span style="font-family: Arial, Helvetica, sans-serif; background-color: rgb(255, 255, 255);"> </span>
3. 在项目的 maven bulider中的Goals输入如下内容
deploy:deploy-file -DgroupId=com.ivifi.tools -DartifactId=ivifi.tools -Dversion=1.0-SNAPSHOT -Dpackaging=jar -Dfile=D:\git\tools\visn.tools\target\ivifi.tools-1.0-SNAPSHOT.jar -Durl=http://192.168.xx.xx:8081/nexus/content/repositories/thirdparty/ -DrepositoryId=thirdparty
0 0
- eclipse中maven插件上传项目jar包到私服
- 使用eclipse maven插件实现上传和下载jar包
- eclipse中用maven 插件把项目打包成jar
- eclipse中maven插件新建web项目
- MAVEN 上传jar包到私服
- maven上传jar包到私服
- 在Eclipse中安装Maven插件以及创建Maven项目
- eclipse中安装maven插件及创建maven项目
- 在Eclipse中安装maven插件以及创建maven项目
- 在eclipse中图形化添加maven项目jar包
- eclipse中maven项目jar包不在同一个目录下
- eclipse中maven项目jar包不会自动下载解决办法
- eclipse中maven项目jar包不会自动下载解决办法
- eclipse中maven项目jar包下载失败解决办法
- eclipse中maven项目jar包不会自动下载解决办法
- 在eclipse中maven项目添加本地jar
- eclipse maven项目中使用tomcat插件部署项目
- Eclipse中Maven插件
- 详细解说STL string
- 背景音乐
- Oracle 存储过程创建和执行入门实例
- C++ Primer学习笔记(7)——指针形参和引用形参的比较
- 关于SoftReference,WeakReference的简单了解
- eclipse中maven插件上传项目jar包到私服
- Windows显示驱动中读取EDID
- Android ListView使用详解
- java基础之基本语法
- [华为机试练习题]50.求M的N次方的最后三位
- GridView导出Excel的超好例子
- 【c语言】模拟库函数strstr
- ‘Starting Tomcat v6.0 Server at localhost’ has encountered a problem
- 缓冲区溢出学习