CVS: TapestryBook/examples .cvsignore,1.2,1.3 build.xml,1.3,1.4 jetty.xml,1.1,NONE build.properties,1.2,NONE

Howard Lewis Ship <[email protected]> Fri, 11 Jul 2003 21:16:47 -0700
Newsgroups gmane.comp.java.tapestry.cvs
Message-ID <[email protected]>
Update of /cvsroot/tapestry/TapestryBook/examples
In directory sc8-pr-cvs1:/tmp/cvs-serv6871/examples

Modified Files:
	.cvsignore build.xml 
Removed Files:
	jetty.xml build.properties 
Log Message:
Reorganize examples application to reflect standard organization

Index: .cvsignore
===================================================================
RCS file: /cvsroot/tapestry/TapestryBook/examples/.cvsignore,v
retrieving revision 1.2
retrieving revision 1.3
diff -C2 -d -r1.2 -r1.3
*** .cvsignore	29 Jun 2003 23:40:25 -0000	1.2
--- .cvsignore	12 Jul 2003 04:16:45 -0000	1.3
***************
*** 1,2 ****
--- 1,3 ----
  examples.war
  classes
+ target

Index: build.xml
===================================================================
RCS file: /cvsroot/tapestry/TapestryBook/examples/build.xml,v
retrieving revision 1.3
retrieving revision 1.4
diff -C2 -d -r1.3 -r1.4
*** build.xml	29 Jun 2003 23:40:25 -0000	1.3
--- build.xml	12 Jul 2003 04:16:45 -0000	1.4
***************
*** 3,53 ****
  <project name="Examples" default="war">
  
! 	<property name="war.file" value="examples.war"/>
! 	<property file="build.properties"/>
  	
  	<path id="project.class.path">
  		<fileset dir="${tapestry.dist.dir}/lib">
  			<include name="*.jar"/>
  			<include name="**/*.jar"/>
  		</fileset>
! 		<pathelement location="${tomcat.dir}/common/lib/servlet.jar"/>
  	</path>
  	
  	<target name="clean" description="Deletes derived files.">
! 		<delete dir="classes" quiet="true"/>
! 		<delete file="${war.file}" quiet="true"/>
  	</target>
  	
  	<target name="compile" description="Compile Java classes.">
! 		<mkdir dir="classes"/>
! 		<javac srcdir="src" destdir="classes" debug="on"
  			classpathref="project.class.path"/>
  	</target>
  	
  	<target name="war" depends="compile"
! 		description="Compile all classes and build the installed WAR.">
! 		<war warfile="${war.file}" webxml="context/WEB-INF/web.xml">
! 			<fileset dir="context">
  				<exclude name="WEB-INF/web.xml"/>
- 				<exclude name="**/Thumbs.db"/>
  	 		</fileset>
! 			<classes dir="classes"/>
! 			<classes dir="src">
  				<exclude name="**/*.java"/>
  				<exclude name="**/package.html"/>
  			</classes>
! 			<classes dir="conf"/>
  			<lib dir="${tapestry.dist.dir}/lib">
! 			  <include name="tapestry*.jar"/>
  			</lib>
  			<lib dir="${tapestry.dist.dir}/lib/ext">
  				<include name="*.jar"/>
  			</lib>
! 			<lib dir="${tapestry.dist.dir}/lib/runtime">
  				<include name="*.jar"/>
! 			</lib>
! 			<lib dir="${jython.dir}">
! 				<include name="jython.jar"/>
! 			</lib>
  		</war>
  	</target>
--- 3,91 ----
  <project name="Examples" default="war">
  
! 	<!-- Customize this to match the desire name. -->
! 	
! 	<property name="project.name" value="examples"/>
! 	
! 	<!-- Find out where other project's distributions are. -->
! 	
! 	<property file="../common/build.properties"/>
! 	
! 	<!-- All derived files end up somewhere under target. -->
  	
+ 	<property name="target.dir" value="target"/>
+ 	
+ 	<property name="src.dir" value="src/java"/>
+ 	<property name="context.dir" value="src/context"/>
+ 	<property name="conf.dir" value="src/conf"/>
+ 			
+ 	<property name="classes.dir" value="${target.dir}/classes"/>
+ 	<property name="war.file" value="${target.dir}/${project.name}.war"/>
+ 	
+ 	<!-- We expect Tomcat to be available. -->
+ 	
+ 	<property name="servlet.jar" value="${tomcat.dir}/common/lib/servlet.jar"/>
+ 		
  	<path id="project.class.path">
  		<fileset dir="${tapestry.dist.dir}/lib">
+ 		
+ 			<!-- The Tapestry JARs -->
  			<include name="*.jar"/>
+ 			
+ 			<!-- Dependencies of Tapestry. -->
+ 			
  			<include name="**/*.jar"/>
  		</fileset>
! 		<pathelement location="${servlet.jar}"/>
  	</path>
  	
  	<target name="clean" description="Deletes derived files.">
! 		<delete dir="${target.dir}" quiet="true"/>
  	</target>
  	
  	<target name="compile" description="Compile Java classes.">
! 		<mkdir dir="${classes.dir}"/>
! 		<javac srcdir="${src.dir}" destdir="${classes.dir}" debug="on"
  			classpathref="project.class.path"/>
  	</target>
  	
  	<target name="war" depends="compile"
! 		description="Compile all classes and build the WAR.">
! 		<war warfile="${war.file}" webxml="${context.dir}/WEB-INF/web.xml">
! 		
! 			<!-- Copy everything in the context directory to the root of the WAR, including
! 			     everything in WEB-INF, except for the web.xml, which the <war> task
! 			     strangely demands be seperate. -->
! 			     
! 			<fileset dir="${context.dir}">
  				<exclude name="WEB-INF/web.xml"/>
  	 		</fileset>
! 	 		
! 	 		<!-- Pick up compiled classes.  These go into WEB-INF/classes.  -->
! 	 		
! 			<classes dir="${classes.dir}"/>
! 						
! 			<!-- Pick up properties files and such from the Java source directory. -->
! 			
! 			<classes dir="${src.dir}">
  				<exclude name="**/*.java"/>
  				<exclude name="**/package.html"/>
  			</classes>
! 			
! 			<!-- There isn't a way to flatten, so we need to do this XXX times. --> 
! 			
  			<lib dir="${tapestry.dist.dir}/lib">
! 			  <include name="*.jar"/>
  			</lib>
+ 			
+ 			<!-- Pick up the main Tapestry dependencies. -->
+ 			
  			<lib dir="${tapestry.dist.dir}/lib/ext">
  				<include name="*.jar"/>
  			</lib>
! 			
! 			<!-- lib dir="${tapestry.dist.dir}/lib/runtime">
  				<include name="*.jar"/>
! 			</lib-->
! 
  		</war>
  	</target>
***************
*** 56,63 ****
  		description="Deploy the WAR into Tomcat.">
  		
  		<property name="deploy.dir" value="${tomcat.dir}/webapps"/>
  		
  		<copy file="${war.file}" todir="${deploy.dir}"/>
- 		<delete dir="${tomcat.dir}/webapps/examples" quiet="yes"/>
  	</target>
  </project>
--- 94,102 ----
  		description="Deploy the WAR into Tomcat.">
  		
+ 		<!-- You can deploy elsewhere by setting deploy.dir in the build.properties file. -->
+ 		
  		<property name="deploy.dir" value="${tomcat.dir}/webapps"/>
  		
  		<copy file="${war.file}" todir="${deploy.dir}"/>
  	</target>
  </project>

--- jetty.xml DELETED ---

--- build.properties DELETED ---



-------------------------------------------------------
This SF.Net email sponsored by: Parasoft
Error proof Web apps, automate testing & more.
Download & eval WebKing and get a free book.
www.parasoft.com/bulletproofapps1