maven 下载源码
2016-03-22 15:42
288 查看
1:Maven命令下载源码和javadocs
当在IDE中使用Maven时如果想要看引用的jar包中类的源码和javadoc需要通过maven命令下载这些源码,然后再进行引入,通过mvn命令能够容易的达到这个目的:mvn dependency:sources
mvn dependency:resolve -Dclassifier=javadoc命令使用方法:首先进入到相应的pom.xml目录中,然后执行以上命令:
第一个命令是尝试下载在pom.xml中依赖的文件的源代码。
第二个命令:是尝试下载对应的javadocs
但是有可能一些文件没有源代码或者javadocs
reference
2:通过配置文件添加
打开maven配置文件 setting.xml文件(.../.m2/settings.xml) 增加如下配置:[html] view
plain copy
<profiles>
<profile>
<id>downloadSources</id>
<properties>
<downloadSources>true</downloadSources>
<downloadJavadocs>true</downloadJavadocs>
</properties>
</profile>
</profiles>
<activeProfiles>
<activeProfile>downloadSources</activeProfile>
</activeProfiles>
3:配置eclipse
Window > Preferences > Maven and checking the "Download Artifact Sources" and "Download Artifact JavaDoc"options
相关文章推荐
- 如何学习?
- 使用runtime关联对象将视图添加到视图的类目里
- Dialog对话框
- Vmware vSphere 6.0之安装 vCenter Server Appliance
- Qt实现网络数据传输 HttpClient
- 工具类:在 PCH 文件中宏定义一个取色方法
- 图片按钮来代替文件上传控件(Freemaker,JQuery,HTML,CSS,JavaScript)
- iOS 身份证验证(转)
- ultragrid checkbox
- surf特征提取后在两幅图像中绘制对应线条
- 数据挖掘第一课学习笔记(Apriori算法和FPTree算法)
- 基于jquery实现无限级树形菜单
- 数据存储——SharedPreferences
- perror()函数
- MySql 外键约束 FOREIGN KEY REFERENCES 之 空、RESTRICT、NO ACTION、CASCADE、SET NULL 等类型分析和作用解读
- iOS [UIScreen mainScreen].bounds 获取屏幕大小不对的问题
- 阿里中间件——消息中间件Notify和MetaQ
- stringByAddingPercentEscapesUsingEncoding:《iOS9中禁用》
- EXT.NET学习笔记(一) 下载配置使用
- 第三次例会