首页 诗词 字典 板报 句子 名言 友答 励志 学校 网站地图
当前位置: 首页 > 教程频道 > 软件管理 > 软件开发 >

自动封装,发布源代码

2012-10-05 
自动打包,发布源代码maven-source-plugin提供项目自动将源码打包并发布的功能:pluginartifactIdmaven-

自动打包,发布源代码
maven-source-plugin提供项目自动将源码打包并发布的功能:

<plugin><artifactId>maven-source-plugin</artifactId><version>2.1.2</version><executions><execution><goals><goal>jar</goal></goals></execution></executions></plugin>


mvn install,maven会自动将source install到repository
mvn deploy,maven会自动将source deploy到remote-repository

注意:在多项目构建中,将source-plugin置于顶层或parent的pom中并不会发挥作用,必须置于具体项目的pom中

资料:http://www.avajava.com/tutorials/lessons/how-do-i-generate-and-deploy-a-source-jar-file-for-my-project.html?page=1

热点排行