首页 > 代码库 > maven source javadoc下载

maven source javadoc下载

1.只下载项目的sources 和 javadoc(省时间)

在pom.xml 

<build>
<finalName>spring-security-loginform-database</finalName>
<plugins>
<plugin>
<artifactId>maven-compiler-plugin</artifactId>
<configuration>
<source>1.6</source>
<target>1.6</target>
<downloadSources>true</downloadSources>
                    <downloadJavadocs>true</downloadJavadocs>
</configuration>
</plugin>
</plugins>
</build>

2.本地仓库下载 sources 和javadoc

setting.xml

<profiles>
<profile>
    <id>downloadSources</id>
    <properties>
        <downloadSources>true</downloadSources>
        <downloadJavadocs>true</downloadJavadocs>           
    </properties>
</profile>
</profiles>


<activeProfiles>
  <activeProfile>downloadSources</activeProfile>
</activeProfiles>

参考:

http://stackoverflow.com/questions/2059431/get-source-jars-from-maven-repository

http://blog.csdn.net/topwqp/article/details/8902863

maven source javadoc下载