portals-jetspeed-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From tay...@apache.org
Subject cvs commit: jakarta-jetspeed maven.xml
Date Mon, 02 Aug 2004 18:54:17 GMT
taylor      2004/08/02 11:54:17

  Modified:    .        maven.xml
  Log:
  copy over templates during fusion deploy
  
  CVS: ----------------------------------------------------------------------
  CVS: PR:
  CVS:   If this change addresses a PR in the problem report tracking
  CVS:   database, then enter the PR number(s) here.
  CVS: Obtained from:
  CVS:   If this change has been taken from another system, such as NCSA,
  CVS:   then name the system in this line, otherwise delete it.
  CVS: Submitted by:
  CVS:   If this code has been contributed to Apache by someone else; i.e.,
  CVS:   they sent us a patch or a new module, then include their name/email
  CVS:   address here. If this is your work then delete this line.
  CVS: Reviewed by:
  CVS:   If we are doing pre-commit code reviews and someone else has
  CVS:   reviewed your changes, include their name(s) here.
  CVS:   If you have not had it reviewed then delete this line.
  
  Revision  Changes    Path
  1.32      +345 -337  jakarta-jetspeed/maven.xml
  
  Index: maven.xml
  ===================================================================
  RCS file: /home/cvs/jakarta-jetspeed/maven.xml,v
  retrieving revision 1.31
  retrieving revision 1.32
  diff -u -r1.31 -r1.32
  --- maven.xml	30 Jul 2004 19:17:32 -0000	1.31
  +++ maven.xml	2 Aug 2004 18:54:17 -0000	1.32
  @@ -13,17 +13,17 @@
   See the License for the specific language governing permissions and
   limitations under the License.
   -->
  -<project default="jar:jar" 
  -		xmlns:j="jelly:core"
  -		xmlns:maven="jelly:maven" 
  -		xmlns:u="jelly:util"
  -		xmlns:m="maven"
  -		xmlns:castor="castor">
  +<project default="jar:jar"
  +        xmlns:j="jelly:core"
  +        xmlns:maven="jelly:maven"
  +        xmlns:u="jelly:util"
  +        xmlns:m="maven"
  +        xmlns:castor="castor">
   
  -	<goal name="allClean"
  +    <goal name="allClean"
           description="Clean the master project and all subprojects">
   
  -		<maven:reactor
  +        <maven:reactor
                  basedir="${basedir}"
                  includes="fusion/project.xml"
                  excludes=""
  @@ -31,15 +31,15 @@
                  banner="Cleaning"
                  ignoreFailures="false"/>
   
  -	    <attainGoal name="clean"/>
  -		
  -	</goal>
  +        <attainGoal name="clean"/>
   
  -	<preGoal name="war:init">  	
  +    </goal>
  +
  +    <preGoal name="war:init">
        <attainGoal name= "jar:install"/>
  -     
  +
        <j:if test="${org.apache.jetspeed.fusion}">
  -	     <maven:reactor
  +         <maven:reactor
                  basedir="${basedir}"
                  includes="fusion/project.xml"
                  excludes=""
  @@ -47,360 +47,368 @@
                  banner="Building Fusion"
                  ignoreFailures="false"/>
        </j:if>
  -     
  +
        <j:set var="maven.test.skip" value="true" />
        <echo>Testing flag is: ${maven.test.skip} for war:install</echo>
   
       </preGoal>
  -  
  -    <postGoal name="war:install">  	
  +
  +    <postGoal name="war:install">
         <j:set var="maven.test.skip" value="false" />
       </postGoal>
  -    
  +
       <postGoal name="war:webapp">
           <j:if test="${org.apache.jetspeed.fusion}">
  -		    <copy 
  -				file="etc/fusion-web.xml" 
  -				tofile="${maven.war.webapp.dir}/WEB-INF/web.xml" 
  -				overwrite="true"/>
  -		    <copy file="${maven.war.src}/WEB-INF/conf/fusion.properties" tofile="${maven.war.webapp.dir}/WEB-INF/conf/fusion.properties"
overwrite="true">
  -		      <filterset begintoken="@" endtoken="@">
  -        	    <filter token="AUTODEPLOYMENT_USER" value="${org.apache.jetspeed.services.autodeployment.user}"/>
  +            <copy
  +                todir="${maven.war.webapp.dir}/WEB-INF/templates/vm/portlets/html/"
  +                overwrite="true">
  +                <fileset dir="fusion/src/webapp/WEB-INF/templates/vm/portlets/html/">
  +                    <exclude name="CVS"/>
  +                    <include name="**.vm"/>
  +                </fileset>
  +            </copy>
  +            <copy
  +                file="etc/fusion-web.xml"
  +                tofile="${maven.war.webapp.dir}/WEB-INF/web.xml"
  +                overwrite="true"/>
  +            <copy file="${maven.war.src}/WEB-INF/conf/fusion.properties" tofile="${maven.war.webapp.dir}/WEB-INF/conf/fusion.properties"
overwrite="true">
  +              <filterset begintoken="@" endtoken="@">
  +                <filter token="AUTODEPLOYMENT_USER" value="${org.apache.jetspeed.services.autodeployment.user}"/>
                   <filter token="AUTODEPLOYMENT_PASSWORD" value="${org.apache.jetspeed.services.autodeployment.password}"/>
                 </filterset>
  -            </copy>        
  -	        <j:forEach var="lib" items="${pom.artifacts}">
  -	            <j:set var="dep" value="${lib.dependency}"/>
  -	     	    <!--<echo>Dep: ${dep.getArtifactId()} ${dep.getProperty('fusion.include')</echo>-->
  -		        <j:if test="${dep.getProperty('fusion.include')=='true'}">
  -		     	    <j:if test="${dep.type =='jar'}"> 
  -			            <copy todir="${maven.war.webapp.dir}/WEB-INF/lib" file="${lib.path}"/>
 
  -			        </j:if> 
  -			         
  -			         <j:if test="${dep.type =='tld'}"> 
  -			             <copy todir="${maven.war.webapp.dir}/${maven.war.tld.dir}" file="${lib.path}"/>
 
  -			         </j:if> 
  -		        </j:if>
  -	        </j:forEach>
  -        
  -	        <!-- define custom task for oeverriding properties -->
  -	        <taskdef name="props_override" classname="org.apache.jetspeed.util.ant.OverwritePropertiesTask">
  -	            <classpath>
  -	                <path refid="maven.dependency.classpath"/>
  -	                <pathelement path="${maven.build.dest}" />
  -	            </classpath>
  -	        </taskdef>
  -	        
  -	        <j:set var="fusion.properties.merge.dir" value="fusion/src/webapp/WEB-INF/conf"/>
  -	        
  -	        <!-- set proper environment property files -->
  -	        <echo>Targeting ${maven.env.name} environment ...</echo>
  -	        <j:set var="props.dir" value="${maven.war.webapp.dir}/WEB-INF/conf"/>
  -	        <echo>Props dir: ${props.dir}</echo>
  -	        
  -	        <u:tokenize var="merge.prop.files" delim=", ">${maven.merge.properties}</u:tokenize>
  -	        <j:forEach items="${merge.prop.files}" var="prop.file">
  -	            <u:available file="${props.dir}/${prop.file}-${maven.env.name}.properties.merge">
  -			        <echo>Merging ${prop.file} for ${maven.env.name}...</echo>
  -					<props_override mergeBaseProperties="${props.dir}/${prop.file}.properties" mergeProperties="${props.dir}/${prop.file}-${maven.env.name}.properties.merge"
includesDir="${props.dir}" failonerror="false"/>
  -	            </u:available>
  -			    <u:available file="${fusion.properties.merge.dir}/${prop.file}.properties.merge">
  -			        <echo>Merging ${prop.file}...</echo>			
  -					<props_override mergeBaseProperties="${props.dir}/${prop.file}.properties" mergeProperties="${fusion.properties.merge.dir}/${prop.file}.properties.merge"
includesDir="${props.dir}" failonerror="false"/>
  -			    </u:available>		
  -	        </j:forEach>
  +            </copy>
  +            <j:forEach var="lib" items="${pom.artifacts}">
  +                <j:set var="dep" value="${lib.dependency}"/>
  +                <!--<echo>Dep: ${dep.getArtifactId()} ${dep.getProperty('fusion.include')</echo>-->
  +                <j:if test="${dep.getProperty('fusion.include')=='true'}">
  +                    <j:if test="${dep.type =='jar'}">
  +                        <copy todir="${maven.war.webapp.dir}/WEB-INF/lib" file="${lib.path}"/>
  +                    </j:if>
  +
  +                     <j:if test="${dep.type =='tld'}">
  +                         <copy todir="${maven.war.webapp.dir}/${maven.war.tld.dir}"
file="${lib.path}"/>
  +                     </j:if>
  +                </j:if>
  +            </j:forEach>
  +
  +            <!-- define custom task for oeverriding properties -->
  +            <taskdef name="props_override" classname="org.apache.jetspeed.util.ant.OverwritePropertiesTask">
  +                <classpath>
  +                    <path refid="maven.dependency.classpath"/>
  +                    <pathelement path="${maven.build.dest}" />
  +                </classpath>
  +            </taskdef>
  +
  +            <j:set var="fusion.properties.merge.dir" value="fusion/src/webapp/WEB-INF/conf"/>
  +
  +            <!-- set proper environment property files -->
  +            <echo>Targeting ${maven.env.name} environment ...</echo>
  +            <j:set var="props.dir" value="${maven.war.webapp.dir}/WEB-INF/conf"/>
  +            <echo>Props dir: ${props.dir}</echo>
  +
  +            <u:tokenize var="merge.prop.files" delim=", ">${maven.merge.properties}</u:tokenize>
  +            <j:forEach items="${merge.prop.files}" var="prop.file">
  +                <u:available file="${props.dir}/${prop.file}-${maven.env.name}.properties.merge">
  +                    <echo>Merging ${prop.file} for ${maven.env.name}...</echo>
  +                    <props_override mergeBaseProperties="${props.dir}/${prop.file}.properties"
mergeProperties="${props.dir}/${prop.file}-${maven.env.name}.properties.merge" includesDir="${props.dir}"
failonerror="false"/>
  +                </u:available>
  +                <u:available file="${fusion.properties.merge.dir}/${prop.file}.properties.merge">
  +                    <echo>Merging ${prop.file}...</echo>
  +                    <props_override mergeBaseProperties="${props.dir}/${prop.file}.properties"
mergeProperties="${fusion.properties.merge.dir}/${prop.file}.properties.merge" includesDir="${props.dir}"
failonerror="false"/>
  +                </u:available>
  +            </j:forEach>
           </j:if>
       </postGoal>
  -	
  -	<!-- ================================================================== -->
  -	<!-- D I S T R I B U T I O N   G O A L S                         -->
  -	<!-- ================================================================== -->
  -	<goal name="dist:prepare-bin-filesystem" description="Builds the binary distribution
file system.">
  -		<!--    
  +
  +    <!-- ================================================================== -->
  +    <!-- D I S T R I B U T I O N   G O A L S                         -->
  +    <!-- ================================================================== -->
  +    <goal name="dist:prepare-bin-filesystem" description="Builds the binary distribution
file system.">
  +        <!--
       This is the directory where everything is copied to so that it can
  -    be archived.    
  +    be archived.
       -->
  -		<delete dir="${maven.dist.bin.assembly.dir}"/>
  -		<mkdir dir="${maven.dist.bin.assembly.dir}"/>
  -		<echo>
  +        <delete dir="${maven.dist.bin.assembly.dir}"/>
  +        <mkdir dir="${maven.dist.bin.assembly.dir}"/>
  +        <echo>
   +------------------------------------------------------------------------+
   | C R E A T I N G  J E T S P E E D  B I N A R Y  D I S T R I B U T I O N |
   +------------------------------------------------------------------------+
  -    		</echo>
  -		<copy todir="${maven.dist.bin.assembly.dir}">
  -			<fileset dir=".">
  -				<include name="NOTES"/>
  -				<include name="LICENSE"/>
  -				<include name="Activation-License.txt"/>
  -				<include name="WARNING"/>
  -				<include name="README"/>
  -				<include name="INSTALL"/>
  -				<include name="FIXES.html"/>
  -				<include name="project.xml"/>
  -			</fileset>
  -		</copy>
  -		<attainGoal name="war"/>
  -		<copy todir="${maven.dist.bin.assembly.dir}">
  -			<fileset dir="${maven.build.dir}">
  -				<include name="*.war"/>
  -			</fileset>
  -		</copy>
  -	</goal>
  -	<goal name="dist:prepare-src-filesystem" description="Builds the source distribution
file system.">
  -		<!-- S O U R C E  D I S T R I B U T I O N -->
  -		<delete dir="${maven.dist.src.assembly.dir}"/>
  -		<mkdir dir="${maven.dist.src.assembly.dir}"/>
  -		<echo>
  +            </echo>
  +        <copy todir="${maven.dist.bin.assembly.dir}">
  +            <fileset dir=".">
  +                <include name="NOTES"/>
  +                <include name="LICENSE"/>
  +                <include name="Activation-License.txt"/>
  +                <include name="WARNING"/>
  +                <include name="README"/>
  +                <include name="INSTALL"/>
  +                <include name="FIXES.html"/>
  +                <include name="project.xml"/>
  +            </fileset>
  +        </copy>
  +        <attainGoal name="war"/>
  +        <copy todir="${maven.dist.bin.assembly.dir}">
  +            <fileset dir="${maven.build.dir}">
  +                <include name="*.war"/>
  +            </fileset>
  +        </copy>
  +    </goal>
  +    <goal name="dist:prepare-src-filesystem" description="Builds the source distribution
file system.">
  +        <!-- S O U R C E  D I S T R I B U T I O N -->
  +        <delete dir="${maven.dist.src.assembly.dir}"/>
  +        <mkdir dir="${maven.dist.src.assembly.dir}"/>
  +        <echo>
   +------------------------------------------------------------------------+
   | C R E A T I N G  J E T S P E E D  S O U R C E  D I S T R I B U T I O N |
   +------------------------------------------------------------------------+
  -    		</echo>
  -		<attainGoal name="xdoc:init"/>
  -		<attainGoal name="jar:jar"/>
  -		<attainGoal name="javadoc:generate"/>
  -		<copy todir="${maven.dist.src.assembly.dir}">
  -			<fileset dir=".">
  -				<!--include name="**/plugin/**"/-->
  -				<exclude name="**/target/**"/>
  -				<exclude name="**/plugin/target/**"/>
  -				<exclude name="**/tutorial/target/**"/>
  -				<exclude name="**/build/**"/>
  -				<exclude name="**/bin/**"/>
  -				<exclude name="**/lib/**"/>				
  -				<exclude name="**/temp/**"/>				
  -				<exclude name="**/*.log"/>
  -				<exclude name="**/*.log.1"/>				
  -				<exclude name="**/marshalled.psml"/>				
  -				<exclude name="**/*.generation"/>								
  -			</fileset>
  -		</copy>
  -	</goal>
  -	<!-- ================================================================== -->
  -	<!-- I N S T A L L  I N  L O C A L  R E P O S I T O R Y   G O A L                 
        -->
  -	<!-- ================================================================== -->
  -	<goal name="dist:install" prereqs="dist:build" description="Install the distributions
into the local repository">
  -		<property name="distdir__" value="${maven.repo.local}/${pom.artifactId}/distributions"/>
  -		<mkdir dir="${distdir__}"/>
  -		<copy todir="${distdir__}">
  -			<fileset dir="${maven.dist.dir}">
  -				<include name="**"/>
  -			</fileset>
  -		</copy>
  -		<attainGoal name="jar:install"/>
  -	</goal>
  -	
  -	<!--
  -	<goal name="jar:install" prereqs="java:jar" description="Install the jar into the local
repository">
  -		<property name="jardir__" value="${maven.repo.local}/${pom.artifactId}/jars"/>
  -		<mkdir dir="${jardir__}"/>
  -		<copy todir="${jardir__}">
  -			<fileset dir="${maven.build.dir}">
  -				<include name="*.jar"/>
  -			</fileset>
  -		</copy>
  -	</goal>
  -	-->
  -	
  -	
  -	<!-- ================================================================== -->
  -	<!--C O P Y  L O C A L I Z A T I O N   R E S O U R C E S                          -->
  -	<!-- ================================================================== -->
  -	<postGoal name="java:jar-resources">
  -		<property name="base.package" value="org/apache/jetspeed/modules/localization"/>
  -		<copy todir="${maven.build.dest}/${base.package}" overwrite="true">
  -			<fileset dir="${pom.build.sourceDirectory}/${base.package}">
  -				<include name="**.properties*"/>
  -			</fileset>
  -		</copy>
  -	</postGoal>
  -	<!-- ================================================================== -->
  -	<!--H O T D E P L O Y   W E B A P P                        -->
  -	<!-- ================================================================== -->
  -	<goal name="hotdeploy" prereqs="java:compile" description="Hot deploys webapp classes
on a local server">
  -		<!--echo>[DEBUG] maven.src.dir = ${maven.src.dir}</echo>
  -		<echo>[DEBUG] maven.war.src = ${maven.war.src}</echo>
  -		<echo>[DEBUG] maven.build.dir = ${maven.build.dir}</echo>
  -		<echo>[DEBUG] maven.war.build.dir = ${maven.war.build.dir}</echo-->
  -		<copy todir="${maven.war.appserver.home}/webapps/${pom.artifactId}/WEB-INF/classes">
  -			<fileset dir="${maven.build.dir}/classes">
  -				<!-- Do not include test files in the runtime jar -->
  -				<exclude name="**/Test*.*"/>
  -				<exclude name="**/test*.*"/>
  -				<!-- Also exclude the test cactus.properties file -->
  -				<exclude name="cactus.properties"/>
  -			</fileset>
  -		</copy>
  -		<copy todir="${maven.war.appserver.home}/webapps/${pom.artifactId}">
  -			<fileset dir="./webapp">
  -				<exclude name="**/*.properties.merge"/>
  -			</fileset>
  -		</copy>
  -	</goal>
  -	<!-- ================================================================== -->
  -	<!--C R E A T E   T O R Q U E   O M                     -->
  -	<!-- ================================================================== -->
  -	<preGoal name="java:compile">
  -		<!--
  -			This requires Castor 0.9.5.  
  -			But using this version of Castor causes the registry to lock up.
  -			This version of Castor is not the problem, but causes it to appear.
  -			JIRA #JS1-405 deals with this issue.
  -		-->
  -		<!--
  -	    <attainGoal name="castor:prepare-filesystem"/>
  -		<castor:generate 
  -			schema="${maven.src.dir}/xml/jetspeed-portal-content.xsd" 
  -			package="org.apache.jetspeed.xml.api.jcm"
  -			marshal="true"/>
  -		-->
  -		<attainGoal name="prepare.apis"/>
  -		<attainGoal name="torque:om"/>
  -	</preGoal>
  -	<!-- ================================================================== -->
  -	<!--C L E A N - U P   T O R Q U E   O M                     -->
  -	<!-- ================================================================== -->
  -	<preGoal name="clean">
  -		<delete failonerror="false">
  -			<fileset dir="${maven.src.dir}/java" includes="**/*.generation"/>
  -			<fileset dir="${maven.src.dir}/java/org/apache/jetspeed/om/apps/coffees">
  -				<exclude name="CVS"/>
  -				<exclude name="**.html"/>
  -				<include name="**.java"/>
  -			</fileset>
  -			<fileset dir="${maven.src.dir}/java/org/apache/jetspeed/om/apps/coffees/map">
  -				<exclude name="CVS"/>
  -				<exclude name="**.html"/>
  -				<include name="**.java"/>
  -			</fileset>
  -			<fileset dir="${maven.src.dir}/java/org/apache/jetspeed/om/apps/email">
  -				<exclude name="CVS"/>
  -				<exclude name="**.html"/>
  -				<exclude name="EmailInbox.java"/>
  -				<include name="**.java"/>
  -			</fileset>
  -			<fileset dir="${maven.src.dir}/java/org/apache/jetspeed/om/apps/email/map">
  -				<exclude name="CVS"/>
  -				<exclude name="**.html"/>
  -				<include name="**.java"/>
  -			</fileset>
  -			<fileset dir="${maven.src.dir}/java/org/apache/jetspeed/om/apps/turbine">
  -				<exclude name="CVS"/>
  -				<exclude name="**.html"/>
  -				<include name="**.java"/>
  -			</fileset>
  -			<fileset dir="${maven.src.dir}/java/org/apache/jetspeed/om/apps/turbine/map">
  -				<exclude name="CVS"/>
  -				<exclude name="**.html"/>
  -				<include name="**.java"/>
  -			</fileset>
  -			<fileset dir="${maven.src.dir}/java/org/apache/jetspeed/om/security/turbine">
  -				<exclude name="CVS"/>
  -				<exclude name="**.html"/>
  -				<exclude name="TurbineGroup.java"/>
  -				<exclude name="TurbineRole.java"/>
  -				<exclude name="TurbinePermission.java"/>
  -				<exclude name="TurbineUserPeer.java"/>
  -				<include name="**.java"/>
  -			</fileset>
  -			<fileset dir="${maven.src.dir}/java/org/apache/jetspeed/om/security/turbine/map">
  -				<exclude name="CVS"/>
  -				<exclude name="**.html"/>
  -				<include name="**.java"/>
  -			</fileset>
  -			<fileset dir="${maven.src.dir}/java/org/apache/jetspeed/om/dbpsml/map">
  -				<exclude name="CVS"/>
  -				<exclude name="**.html"/>
  -				<include name="**.java"/>
  -			</fileset>
  -			<fileset dir="${maven.src.dir}/java/org/apache/jetspeed/om/dbpsml">
  -				<exclude name="CVS"/>
  -				<exclude name="**.html"/>
  -				<exclude name="JetspeedGroupProfilePeer.java"/>
  -				<exclude name="JetspeedRoleProfilePeer.java"/>
  -				<exclude name="JetspeedUserProfilePeer.java"/>
  -				<include name="**.java"/>
  -			</fileset>
  -			<fileset dir="${maven.src.dir}/java/org/apache/jetspeed/xml/api/jcm">
  -				<include name="**/*.java"/>
  -				<exclude name="CVS"/>
  -				<exclude name="package.html"/>
  -			</fileset>
  -		</delete>
  -		<!-- Also, need to delete selected sources from security/turbine and dbpsml folders
-->
  -	</preGoal>
  -	<!-- 
  -	=================================================================== 
  -	 Remove unwanted items before the .war is created
  - 	=================================================================== 
  -	-->
  -	<preGoal name="war:war">
  -		<!--This causes tests to be ran twice-->
  -		<!--<attainGoal name="jar"/>	-->
  -		
  -		<echo>Deleting uneeded resources from ${maven.war.webapp.dir}...</echo>
  -		<delete failonerror="false">
  -			<fileset dir="${maven.war.webapp.dir}" includes="**/*.log"/>
  -			<fileset dir="${maven.war.webapp.dir}" includes="**/*.log.1"/>
  -			<!--<fileset dir="${maven.war.webapp.dir}" includes="**/WEB-INF/classes/**"/>
		-->
  -		</delete>
  -		
  -		
  -		<!--
  -		<echo>Copying ${maven.final.name}.jar to ${maven.war.webapp.dir}...</echo>
	
  -		<copy todir="${maven.war.webapp.dir}/WEB-INF/lib">
  -			<fileset dir="${maven.build.dir}">
  -				<include name="${maven.final.name}.jar"/>
  -			</fileset>
  -		</copy>
  -		-->
  -		
  -		<!--
  -		<j:set var="fusion.properties" value="fusion-setup.properties.empty"/>
  -		<j:if test="${org.apache.jetspeed.fusion}">
  -			<j:set var="fusion.properties" value="fusion-setup.properties.full"/>
  -		</j:if>
  -		
  -		<copy tofile="${maven.war.webapp.dir}/WEB-INF/conf/fusion-setup.properties" file="fusion/src/webapp/WEB-INF/conf/${fusion.properties}"
/>
  -		-->
  -	</preGoal>	
  -	
  -    <goal name="deploy" description="Deploys jetspeed.war on a local server">   
    
  -        <delete dir="${maven.war.appserver.home}/webapps/${pom.artifactId}"/> 
  +            </echo>
  +        <attainGoal name="xdoc:init"/>
  +        <attainGoal name="jar:jar"/>
  +        <attainGoal name="javadoc:generate"/>
  +        <copy todir="${maven.dist.src.assembly.dir}">
  +            <fileset dir=".">
  +                <!--include name="**/plugin/**"/-->
  +                <exclude name="**/target/**"/>
  +                <exclude name="**/plugin/target/**"/>
  +                <exclude name="**/tutorial/target/**"/>
  +                <exclude name="**/build/**"/>
  +                <exclude name="**/bin/**"/>
  +                <exclude name="**/lib/**"/>
  +                <exclude name="**/temp/**"/>
  +                <exclude name="**/*.log"/>
  +                <exclude name="**/*.log.1"/>
  +                <exclude name="**/marshalled.psml"/>
  +                <exclude name="**/*.generation"/>
  +            </fileset>
  +        </copy>
  +    </goal>
  +    <!-- ================================================================== -->
  +    <!-- I N S T A L L  I N  L O C A L  R E P O S I T O R Y   G O A L              
           -->
  +    <!-- ================================================================== -->
  +    <goal name="dist:install" prereqs="dist:build" description="Install the distributions
into the local repository">
  +        <property name="distdir__" value="${maven.repo.local}/${pom.artifactId}/distributions"/>
  +        <mkdir dir="${distdir__}"/>
  +        <copy todir="${distdir__}">
  +            <fileset dir="${maven.dist.dir}">
  +                <include name="**"/>
  +            </fileset>
  +        </copy>
  +        <attainGoal name="jar:install"/>
  +    </goal>
  +
  +    <!--
  +    <goal name="jar:install" prereqs="java:jar" description="Install the jar into the
local repository">
  +        <property name="jardir__" value="${maven.repo.local}/${pom.artifactId}/jars"/>
  +        <mkdir dir="${jardir__}"/>
  +        <copy todir="${jardir__}">
  +            <fileset dir="${maven.build.dir}">
  +                <include name="*.jar"/>
  +            </fileset>
  +        </copy>
  +    </goal>
  +    -->
  +
  +
  +    <!-- ================================================================== -->
  +    <!--C O P Y  L O C A L I Z A T I O N   R E S O U R C E S                       
  -->
  +    <!-- ================================================================== -->
  +    <postGoal name="java:jar-resources">
  +        <property name="base.package" value="org/apache/jetspeed/modules/localization"/>
  +        <copy todir="${maven.build.dest}/${base.package}" overwrite="true">
  +            <fileset dir="${pom.build.sourceDirectory}/${base.package}">
  +                <include name="**.properties*"/>
  +            </fileset>
  +        </copy>
  +    </postGoal>
  +    <!-- ================================================================== -->
  +    <!--H O T D E P L O Y   W E B A P P                        -->
  +    <!-- ================================================================== -->
  +    <goal name="hotdeploy" prereqs="java:compile" description="Hot deploys webapp classes
on a local server">
  +        <!--echo>[DEBUG] maven.src.dir = ${maven.src.dir}</echo>
  +        <echo>[DEBUG] maven.war.src = ${maven.war.src}</echo>
  +        <echo>[DEBUG] maven.build.dir = ${maven.build.dir}</echo>
  +        <echo>[DEBUG] maven.war.build.dir = ${maven.war.build.dir}</echo-->
  +        <copy todir="${maven.war.appserver.home}/webapps/${pom.artifactId}/WEB-INF/classes">
  +            <fileset dir="${maven.build.dir}/classes">
  +                <!-- Do not include test files in the runtime jar -->
  +                <exclude name="**/Test*.*"/>
  +                <exclude name="**/test*.*"/>
  +                <!-- Also exclude the test cactus.properties file -->
  +                <exclude name="cactus.properties"/>
  +            </fileset>
  +        </copy>
  +        <copy todir="${maven.war.appserver.home}/webapps/${pom.artifactId}">
  +            <fileset dir="./webapp">
  +                <exclude name="**/*.properties.merge"/>
  +            </fileset>
  +        </copy>
  +    </goal>
  +    <!-- ================================================================== -->
  +    <!--C R E A T E   T O R Q U E   O M                     -->
  +    <!-- ================================================================== -->
  +    <preGoal name="java:compile">
  +        <!--
  +            This requires Castor 0.9.5.
  +            But using this version of Castor causes the registry to lock up.
  +            This version of Castor is not the problem, but causes it to appear.
  +            JIRA #JS1-405 deals with this issue.
  +        -->
  +        <!--
  +        <attainGoal name="castor:prepare-filesystem"/>
  +        <castor:generate
  +            schema="${maven.src.dir}/xml/jetspeed-portal-content.xsd"
  +            package="org.apache.jetspeed.xml.api.jcm"
  +            marshal="true"/>
  +        -->
  +        <attainGoal name="prepare.apis"/>
  +        <attainGoal name="torque:om"/>
  +    </preGoal>
  +    <!-- ================================================================== -->
  +    <!--C L E A N - U P   T O R Q U E   O M                     -->
  +    <!-- ================================================================== -->
  +    <preGoal name="clean">
  +        <delete failonerror="false">
  +            <fileset dir="${maven.src.dir}/java" includes="**/*.generation"/>
  +            <fileset dir="${maven.src.dir}/java/org/apache/jetspeed/om/apps/coffees">
  +                <exclude name="CVS"/>
  +                <exclude name="**.html"/>
  +                <include name="**.java"/>
  +            </fileset>
  +            <fileset dir="${maven.src.dir}/java/org/apache/jetspeed/om/apps/coffees/map">
  +                <exclude name="CVS"/>
  +                <exclude name="**.html"/>
  +                <include name="**.java"/>
  +            </fileset>
  +            <fileset dir="${maven.src.dir}/java/org/apache/jetspeed/om/apps/email">
  +                <exclude name="CVS"/>
  +                <exclude name="**.html"/>
  +                <exclude name="EmailInbox.java"/>
  +                <include name="**.java"/>
  +            </fileset>
  +            <fileset dir="${maven.src.dir}/java/org/apache/jetspeed/om/apps/email/map">
  +                <exclude name="CVS"/>
  +                <exclude name="**.html"/>
  +                <include name="**.java"/>
  +            </fileset>
  +            <fileset dir="${maven.src.dir}/java/org/apache/jetspeed/om/apps/turbine">
  +                <exclude name="CVS"/>
  +                <exclude name="**.html"/>
  +                <include name="**.java"/>
  +            </fileset>
  +            <fileset dir="${maven.src.dir}/java/org/apache/jetspeed/om/apps/turbine/map">
  +                <exclude name="CVS"/>
  +                <exclude name="**.html"/>
  +                <include name="**.java"/>
  +            </fileset>
  +            <fileset dir="${maven.src.dir}/java/org/apache/jetspeed/om/security/turbine">
  +                <exclude name="CVS"/>
  +                <exclude name="**.html"/>
  +                <exclude name="TurbineGroup.java"/>
  +                <exclude name="TurbineRole.java"/>
  +                <exclude name="TurbinePermission.java"/>
  +                <exclude name="TurbineUserPeer.java"/>
  +                <include name="**.java"/>
  +            </fileset>
  +            <fileset dir="${maven.src.dir}/java/org/apache/jetspeed/om/security/turbine/map">
  +                <exclude name="CVS"/>
  +                <exclude name="**.html"/>
  +                <include name="**.java"/>
  +            </fileset>
  +            <fileset dir="${maven.src.dir}/java/org/apache/jetspeed/om/dbpsml/map">
  +                <exclude name="CVS"/>
  +                <exclude name="**.html"/>
  +                <include name="**.java"/>
  +            </fileset>
  +            <fileset dir="${maven.src.dir}/java/org/apache/jetspeed/om/dbpsml">
  +                <exclude name="CVS"/>
  +                <exclude name="**.html"/>
  +                <exclude name="JetspeedGroupProfilePeer.java"/>
  +                <exclude name="JetspeedRoleProfilePeer.java"/>
  +                <exclude name="JetspeedUserProfilePeer.java"/>
  +                <include name="**.java"/>
  +            </fileset>
  +            <fileset dir="${maven.src.dir}/java/org/apache/jetspeed/xml/api/jcm">
  +                <include name="**/*.java"/>
  +                <exclude name="CVS"/>
  +                <exclude name="package.html"/>
  +            </fileset>
  +        </delete>
  +        <!-- Also, need to delete selected sources from security/turbine and dbpsml
folders -->
  +    </preGoal>
  +    <!--
  +    ===================================================================
  +     Remove unwanted items before the .war is created
  +    ===================================================================
  +    -->
  +    <preGoal name="war:war">
  +        <!--This causes tests to be ran twice-->
  +        <!--<attainGoal name="jar"/>    -->
  +
  +        <echo>Deleting uneeded resources from ${maven.war.webapp.dir}...</echo>
  +        <delete failonerror="false">
  +            <fileset dir="${maven.war.webapp.dir}" includes="**/*.log"/>
  +            <fileset dir="${maven.war.webapp.dir}" includes="**/*.log.1"/>
  +            <!--<fileset dir="${maven.war.webapp.dir}" includes="**/WEB-INF/classes/**"/>
          -->
  +        </delete>
  +
  +
  +        <!--
  +        <echo>Copying ${maven.final.name}.jar to ${maven.war.webapp.dir}...</echo>
  +        <copy todir="${maven.war.webapp.dir}/WEB-INF/lib">
  +            <fileset dir="${maven.build.dir}">
  +                <include name="${maven.final.name}.jar"/>
  +            </fileset>
  +        </copy>
  +        -->
  +
  +        <!--
  +        <j:set var="fusion.properties" value="fusion-setup.properties.empty"/>
  +        <j:if test="${org.apache.jetspeed.fusion}">
  +            <j:set var="fusion.properties" value="fusion-setup.properties.full"/>
  +        </j:if>
  +
  +        <copy tofile="${maven.war.webapp.dir}/WEB-INF/conf/fusion-setup.properties"
file="fusion/src/webapp/WEB-INF/conf/${fusion.properties}" />
  +        -->
  +    </preGoal>
  +
  +    <goal name="deploy" description="Deploys jetspeed.war on a local server">
  +        <delete dir="${maven.war.appserver.home}/webapps/${pom.artifactId}"/>
           <copy  file="${maven.build.dir}/${pom.artifactId}.war" todir="${maven.war.appserver.home}/webapps/">
  -        </copy>		
  +        </copy>
           <unwar src="${maven.war.appserver.home}/webapps/${pom.artifactId}.war" dest="${maven.war.appserver.home}/webapps/${pom.artifactId}"/>
   
  -		<j:if test="${org.apache.jetspeed.fusion}">
  -	        <maven:reactor
  +        <j:if test="${org.apache.jetspeed.fusion}">
  +            <maven:reactor
                  basedir="${basedir}"
                  includes="fusion/project.xml"
                  goals="deployFusion"
                  banner="Deploying Fusion resources..."
                  postProcessing="false"
  -               ignoreFailures="false"/>        
  -		</j:if>               
  -    </goal>    
  +               ignoreFailures="false"/>
  +        </j:if>
  +    </goal>
   
       <goal name="prepare.apis">
  -        <uptodate 
  -            property="apis.uptodate" 
  +        <uptodate
  +            property="apis.uptodate"
               targetfile="${maven.build.dir}/${pom.artifactId}-${pom.currentVersion}.jar"
           >
               <srcfiles dir="${maven.src.dir}/xml" includes="**/*.xsd"/>
  -        </uptodate>        
  -		<j:set var="castorflag" value="${apis.uptodate}"/>        
  -		<j:if test="${castorflag != 'true'}">
  -			<echo>Generating Jetspeed XML bindings</echo>
  -			<java classname="org.exolab.castor.builder.SourceGenerator" fork="yes">
  -				<classpath refid="maven.dependency.classpath"/>
  -				<arg value="-i"/>
  -				<arg value="${maven.src.dir}/xml/jetspeed-portal-content.xsd"/>
  -				<arg value="-f"/>
  -				<arg value="-dest"/>
  -				<arg value="${maven.src.dir}/java"/>
  -				<arg value="-package"/>
  -				<arg value="org.apache.jetspeed.xml.api.jcm"/>
  -			</java>		
  +        </uptodate>
  +        <j:set var="castorflag" value="${apis.uptodate}"/>
  +        <j:if test="${castorflag != 'true'}">
  +            <echo>Generating Jetspeed XML bindings</echo>
  +            <java classname="org.exolab.castor.builder.SourceGenerator" fork="yes">
  +                <classpath refid="maven.dependency.classpath"/>
  +                <arg value="-i"/>
  +                <arg value="${maven.src.dir}/xml/jetspeed-portal-content.xsd"/>
  +                <arg value="-f"/>
  +                <arg value="-dest"/>
  +                <arg value="${maven.src.dir}/java"/>
  +                <arg value="-package"/>
  +                <arg value="org.apache.jetspeed.xml.api.jcm"/>
  +            </java>
           </j:if>
       </goal>
   
  @@ -412,7 +420,7 @@
   
           <java fork="true" classname="org.apache.jetspeed.services.psmlmanager.PsmlImporter"
>
               <!-- comment this out to preserve existing profiles -->
  -			<arg value="false"/>        
  +            <arg value="false"/>
                 <classpath>
                   <path refid="maven.dependency.classpath"/>
                   <pathelement path="${maven.build.dest}"/>
  @@ -428,7 +436,7 @@
   
           <java fork="true" classname="org.apache.jetspeed.services.registry.RegistryImporter"
>
               <!-- comment this out to preserve existing profiles -->
  -			<arg value="false"/>        
  +            <arg value="false"/>
                 <classpath>
                   <path refid="maven.dependency.classpath"/>
                   <pathelement path="${maven.build.dest}"/>
  
  
  

---------------------------------------------------------------------
To unsubscribe, e-mail: jetspeed-dev-unsubscribe@jakarta.apache.org
For additional commands, e-mail: jetspeed-dev-help@jakarta.apache.org


Mime
View raw message