maven2下载依赖包的同时下载其源代码包

来源:互联网 发布:网络维护班组优秀案例 编辑:程序博客网 时间:2024/06/05 22:17

使maven2在下载依赖包的同时下载其源代码包的方法:

1. 使用maven命令:mvn dependency:sources 下载依赖包的源代码。

2. 使用参数: -DdownloadSources=true 下载源代码jar。 -DdownloadJavadocs=true 下载javadoc包。

mvn dependency:sources -DdownloadSources=true -DdownloadJavadocs=true

Eclipse

mvn -DdownloadSources=true -DdownloadJavadocs=true -DoutputDirectory=target/eclipse-classes eclipse:eclipse


eclipseMaven插件就提供了这个功能,只需要勾选windows-Preferences-Maven-DownloadArtifact Sources这个选项就可以了

0 0
原创粉丝点击