[jboss-cvs] jboss-seam/seam-gen ...
Gavin King
gavin.king at jboss.com
Sun Nov 5 16:01:38 EST 2006
User: gavin
Date: 06/11/05 16:01:38
Modified: seam-gen README USAGE build.xml
Removed: seam-gen build-project-setup.xml
build.properties.template
Log:
dont make them type project name many times
Revision Changes Path
1.12 +16 -10 jboss-seam/seam-gen/README
(In the diff below, changes in quantity of whitespace are not shown.)
Index: README
===================================================================
RCS file: /cvsroot/jboss/jboss-seam/seam-gen/README,v
retrieving revision 1.11
retrieving revision 1.12
diff -u -b -r1.11 -r1.12
--- README 5 Nov 2006 19:14:41 -0000 1.11
+++ README 5 Nov 2006 21:01:38 -0000 1.12
@@ -5,7 +5,7 @@
JBoss AS with EJB3 installed.
SYNOPSIS
- seam COMMAND PROJECT_NAME OPTIONS...
+ seam COMMAND [OPTION...]
SEAM PROJECT SETUP/DEPLOYMENT COMMANDS
setup
@@ -22,13 +22,19 @@
Create a new seam project that has all dependencies and minimal
configuration. Refers to build.properties for project attributes.
- Example: seam new-project PROJECT_NAME
+ Example: seam new-project
- deploy-project
+ deploy
Deploy the project EAR and datasource to JBoss. This command
will not work if you created a WTP project.
- Example: seam deploy-project PROJECT_NAME
+ Example: seam deploy
+
+ undeploy
+ Undeploy the project EAR and datasource. This command
+ will not work if you created a WTP project.
+
+ Example: seam undeploy
SEAM CODE GENERATION COMMANDS
new-conversation
@@ -38,7 +44,7 @@
can be used to simulate a JSF request/response and standard
JUnit type tests.
- Example: seam new-conversation PROJECT_NAME CLASS_NAME [PAGE_NAME]
+ Example: seam new-conversation CLASS_NAME [PAGE_NAME]
new-action
Create a new Java interface and SLSB with key Seam/EJB3
@@ -46,7 +52,7 @@
can be used to simulate a JSF request/response and standard
JUnit type tests.
- Example: seam new-action PROJECT_NAME CLASS_NAME [PAGE_NAME]
+ Example: seam new-action CLASS_NAME [PAGE_NAME]
new-form
Create a new Java interface and SFSB with key Seam/EJB3
@@ -54,23 +60,23 @@
can be used to simulate a JSF request/response and standard
JUnit type tests.
- Example: seam new-form PROJECT_NAME CLASS_NAME [PAGE_NAME]
+ Example: seam new-form CLASS_NAME [PAGE_NAME]
new-page
Create a new facelet that refers to template.xhtml for its
layout. If no template.xhtml exists, create one.
- Example: seam new-page PROJECT_NAME [PAGE_NAME]
+ Example: seam new-page PAGE_NAME
new-entity
Create a new EJB3 entity bean with key Seam/EJB3 annotations
and a couple of stub attributes.
- Example: seam new-entity PROJECT_NAME CLASS_NAME [PAGE_NAME] [LIST_PAGE_NAME]
+ Example: seam new-entity CLASS_NAME [PAGE_NAME] [LIST_PAGE_NAME]
new-mdb
Create a new EJB3 MDB with key Seam/EJB3 annotations.
Input prompt for destination type (Topic or Queue).
Input prompt for JMS destination.
- Example: seam new-mdb PROJECT_NAME CLASS_NAME
+ Example: seam new-mdb CLASS_NAME
1.4 +1 -1 jboss-seam/seam-gen/USAGE
(In the diff below, changes in quantity of whitespace are not shown.)
Index: USAGE
===================================================================
RCS file: /cvsroot/jboss/jboss-seam/seam-gen/USAGE,v
retrieving revision 1.3
retrieving revision 1.4
diff -u -b -r1.3 -r1.4
--- USAGE 3 Nov 2006 17:38:58 -0000 1.3
+++ USAGE 5 Nov 2006 21:01:38 -0000 1.4
@@ -1,2 +1,2 @@
-Usage: seam COMMAND PROJECT_NAME OPTION...
+Usage: seam COMMAND [OPTION...]
Try `seam help' for more information.
1.17 +31 -10 jboss-seam/seam-gen/build.xml
(In the diff below, changes in quantity of whitespace are not shown.)
Index: build.xml
===================================================================
RCS file: /cvsroot/jboss/jboss-seam/seam-gen/build.xml,v
retrieving revision 1.16
retrieving revision 1.17
diff -u -b -r1.16 -r1.17
--- build.xml 3 Nov 2006 17:38:58 -0000 1.16
+++ build.xml 5 Nov 2006 21:01:38 -0000 1.17
@@ -147,12 +147,29 @@
</copy>
</target>
- <target name="new-project" depends="file-copy">
- <echo message="Your new Seam project called '${project.name}' has been created" />
+ <target name="set-default-project">
+ <propertyfile file="build.properties">
+ <entry key="project.name" value="${project.name}"/>
+ </propertyfile>
</target>
- <target name="new-wtp-project" depends="file-copy-wtp">
- <echo message="Your new Seam project called '${project.name}' has been created" />
+ <target name="validate-project">
+ <fail message="No project name specified">
+ <condition>
+ <or>
+ <not><isset property="project.name"/></not>
+ <equals arg1="${project.name}" arg2=""/>
+ </or>
+ </condition>
+ </fail>
+ </target>
+
+ <target name="new-project" depends="validate-project,file-copy,set-default-project">
+ <echo message="A new Seam project called '${project.name}' was created in the ${workspace.home} directory"/>
+ </target>
+
+ <target name="new-wtp-project" depends="validate-project,file-copy-wtp,set-default-project">
+ <echo message="A new WTP project was created in the ${workspace.home} directory"/>
</target>
<target name="update-project">
@@ -287,10 +304,14 @@
</java>
</target>
- <target name="deploy-project">
- <echo message="Deploy project to JBoss" />
- <ant antfile="${workspace.home}/${project.name}/build.xml" target="deploy" inheritall="false">
- </ant>
+ <target name="deploy">
+ <echo message="Deploying project '${project.name}' to JBoss" />
+ <ant antfile="${workspace.home}/${project.name}/build.xml" target="deploy" inheritall="false"/>
+ </target>
+
+ <target name="undeploy">
+ <echo message="Undeploying project '${project.name}'" />
+ <ant antfile="${workspace.home}/${project.name}/build.xml" target="undeploy" inheritall="false"/>
</target>
<target name="help">
More information about the jboss-cvs-commits
mailing list