maven +Nexus

maven部分:html

1.maven的下载安装以及配置:见梁总的 Maven下载、安装和配置(二)windows

安装成功后,在cmd中输入 mvn -v 则以下图:浏览器

2.eclipse插件中若是没有maven插件则须要安装插件:见 安装Eclipse Maven插件的几种方法eclipse

安装成功后在eclipse的 windows--->preferences 看到mavenmaven

3. 将eclipse中的插件maven 指向本身安装的Maven:见 Eclipse Java EE IDE for Web Developers集成的Maven 3 指向本身安装的 Mavenpost

 

maven 本地仓储的存放路径,若是没有设置默认就在:C:\Users\cjjuan\.m2\repository 下 ,这个地方须要改到:D:\IDEStrain\maven\repositoryui

4.编译 :选中项目右键 maven---->update project (从远程仓储中下载.jar包)url

5.发布,生成.jar包  spa

选中项目里的pom.xml右键 Run as --->Maven install 则生成.net

运行成功后,生成.jar包到对应的maven本地仓储中,若是有远程仓储中未下载的包,也会一并下载过来

下载远程仓储中未下载的包
[WARNING] Checksum validation failed, could not read expected checksum: Checksum validation failed, expected  but is b240cc62640ad4f91ad65c9f8ae137413f3c62e1 for http://192.168.200.57:8081/nexus/content/groups/public/io/zipkin/brave/brave-instrumentation-parent/4.13.3/brave-instrumentation-parent-4.13.3.pom
[INFO] Downloaded: http://192.168.200.57:8081/nexus/content/groups/public/io/zipkin/brave/brave-instrumentation-parent/4.13.3/brave-instrumentation-parent-4.13.3.pom (3 KB at 6.4 KB/sec)
[INFO] Downloading: http://192.168.200.57:8081/nexus/content/repositories/thirdparty/io/zipkin/brave/brave-spancollector-http/4.13.3/brave-spancollector-http-4.13.3.pom
生成.jar到 target目录
[INFO] --- maven-jar-plugin:2.4:jar (default-jar) @ Service_Basic --- [INFO] Building jar: D:\SMC\platform\Common\Service_Basic\target\Service_Basic-1.2.0.jar 生成.jar和.pom到本地仓储 [INFO] --- maven-install-plugin:2.4:install (default-install) @ Service_Basic --- [INFO] Installing D:\SMC\platform\Common\Service_Basic\target\Service_Basic-1.2.0.jar to D:\IDEStrain\maven\repository\com\cdc\platform\common\Service_Basic\1.2.0\Service_Basic-1.2.0.jar [INFO] Installing D:\SMC\platform\Common\Service_Basic\pom.xml to D:\IDEStrain\maven\repository\com\cdc\platform\common\Service_Basic\1.2.0\Service_Basic-1.2.0.pom [INFO] ------------------------------------------------------------------------ [INFO] BUILD SUCCESS

 Nexus部分:

1.安装与部署

 1.下载开源Nexus: 找最新的下载https://help.sonatype.com/repomanager2/download/download-archives---repository-manager-oss

 nexus-2.14.11-01-bundle.zip  解压到路径:E:\tool\nexus-server

以管理员的身份打开cmd窗口,进入E:\tool\nexus-server\nexus-2.14.11-01\bin ,输入 nexus install 命令,进行安装nexus.

将Nexus安装为Windows服务。可将服务启动方式设为手动

 

之后经过 nexus start 便可启动Nexus ,经过 nexus stop 退出Nexus,也能够直接在服务里手动启动和中止

 

启动成功后,在浏览器中输入:http://localhost:8081/nexus/  进入登陆页面,用帐户admin  密码:admin123 登陆,可以使用更多功能

 

 

 

 

 

Nexus安装、使用说明、问题总结

Maven远程仓库的配置和部署

Maven详解之仓库------本地仓库、远程仓库

 本地Maven仓库部署+Myeclipse本地仓库配置

相关文章
相关标签/搜索