Maven: 定义自己的结构

新建一个 archetype 项目:

mvn archetype:create -DgroupId=com.yunling.conf -DartifactId=prof-archetype -DarchetypeArtifactId=maven-archetype-archetype

模版文件:src/main/resources/archetype-resources/pom.xml

我修改后的内容如下:

pom

安装项目:

cd prof-archetype

mvn install

这样就可以使用它创建新项目:

mvn archetype:create -DgroupId=cn.lingyun.app -DartifactId=webdemo -DarchetypeArtifactId=prof-archetype -DarchetypeVersion=1.0-SNAPSHOT

Technorati 标签: maven
posted @ 2011-03-28 17:24  zh.ethan  阅读(422)  评论(0编辑  收藏  举报