Maven项目的原型模板

7

我想用Maven开始一个小项目。我想使用JSF2和Hibernate。你能推荐一些原型吗?或者其他一些开始这个项目的步骤。

谢谢...


我的建议是远离Maven ;) 但当我使用Maven时,我会在Eclipse中进行,并且向导会自动为我提供原型选择。 - Carl Smotricz
3个回答

5

使用

mvn archetype:generate

会出现一些原型列表。您可能会发现它们有用/教育性,因为其中许多是针对JSF项目的:

1: internal -> appfuse-basic-jsf (AppFuse archetype for creating a web application with Hibernate, Spring and JSF)
...
6: internal -> appfuse-modular-jsf (AppFuse archetype for creating a modular application with Hibernate, Spring and JSF)
...
20: internal -> softeu-archetype-seam (JSF+Facelets+Seam Archetype)
21: internal -> softeu-archetype-seam-simple (JSF+Facelets+Seam (no persistence) Archetype)
22: internal -> softeu-archetype-jsf (JSF+Facelets Archetype)
23: internal -> jpa-maven-archetype (JPA application)
...
39: internal -> myfaces-archetype-jsfcomponents (A simple archetype for create custom JSF components using MyFaces)

我不同意卡尔的观点,继续使用Maven吧!

1
您可以尝试这个:

您可以尝试这个:

mvn archetype:generate -DarchetypeGroupId=com.github.happyfaces -DarchetypeArtifactId=happyfaces-archetype -DarchetypeVersion=1.0.2 -DgroupId=com.test -DartifactId=MyTestApp 

-1

看起来好像想要制造一场战争,不是吗? 因此,我建议您使用war打包方式,这将允许您在开发模式下运行您的Web项目(还请注意,使用m2eclipseeclipse WTP,您可能会获得额外的奖励)。


网页内容由stack overflow 提供, 点击上面的
可以查看英文原文,
原文链接