【发布时间】:2011-03-15 08:17:45
【问题描述】:
我想用 maven 开始一个小项目。我想使用 JSF2 和 Hibernate。你能推荐一些原型吗?或其他一些程序来启动这个项目。
干杯...
【问题讨论】:
-
我的建议是远离 Maven ;) 但是当我使用 Maven 时,我会在 Eclipse 中使用,向导会自动为我提供一系列原型。
标签: java maven-2 maven-archetype
我想用 maven 开始一个小项目。我想使用 JSF2 和 Hibernate。你能推荐一些原型吗?或其他一些程序来启动这个项目。
干杯...
【问题讨论】:
标签: java maven-2 maven-archetype
你可以试试这个:
mvn archetype:generate -DarchetypeGroupId=com.github.happyfaces -DarchetypeArtifactId=happyfaces-archetype -DarchetypeVersion=1.0.2 -DgroupId=com.test -DartifactId=MyTestApp
【讨论】:
使用
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)
(我不同意 Carl 的观点,跟上 maven!)
【讨论】:
好像是想发动一场战争,不是吗?
因此,我可以建议您使用@987654321@ 包装,这将允许您在开发模式下运行您的网络项目(另请注意,使用m2eclipse 和eclipse WTP,您可能会增加奖金)。
【讨论】: