No public targets defined.
<?xml version="1.0" encoding="UTF-8"?>
<project name="src">
<description>
+ ==\_/============J=A=V=A=G=E=N===A=N=T===M=O=D=U=L=E=S================= +
+ \(_)/ +
+ -(_)- Source Distribution Module +
+ /(_)\ +
+ ======================================================================= +
+ Copyright (c) 2002-2005 Outsource Cafe, Inc. All rights reserved. +
+ ======================================================================= +
+
+ Packages typical JAM project source.
+
+ developer: RichardEasterling@OutsourceCafe.com
+ ======================================================================= +
+ Licensed under the Apache License, Version 2.0 (the "License");
+ you may not use this file except in compliance with the License.
+ You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
+ =J=A=M===========================================J=A=V=A=G=E=N=.=C=O=M= +
</description>
<!-- example usage from petstore (note update usage):
<target name="dist.src" depends="" description="create source distribution">
<property name="src.dist.name" value="${project.name}-src-${project.version}"/>
<src.dist.macro destfile="${dist.dir}/${src.dist.name}.zip" rootdir=".." prefix="${src.dist.name}" excludes="**/*.xmi,**/*.xgen,**/*.frag"/>
<src.dist.macro destfile="${dist.dir}/${src.dist.name}.zip" rootdir="../ejb-module" prefix="${src.dist.name}/ejb-module" update="true" excludes="**/props-javagen.xml,**/maven.xml"/>
<src.dist.macro destfile="${dist.dir}/${src.dist.name}.zip" rootdir="../web-module" prefix="${src.dist.name}/web-module" update="true" excludes="**/Thumbs.db,**/props-javagen.xml,**/maven.xml"/>
<src.dist.macro destfile="${dist.dir}/${src.dist.name}.zip" rootdir="../ear" prefix="${src.dist.name}/ear" update="true" excludes="**/props-javagen.xml,**/maven.xml"/>
</target>
-->
<!-- =================================================================== -->
<!-- source zip distribution macro -->
<!-- =================================================================== -->
<macrodef name="src.zip.macro">
<attribute name="destfile" default=""></attribute>
<attribute name="rootdir" default="${basedir}"></attribute>
<attribute name="prefix" default=""></attribute>
<attribute name="update" default="false"></attribute>
<attribute name="excludes" default=""></attribute>
<attribute name="includes" default="*.xml,License,todo.txt,readme.txt"></attribute>
<sequential>
<echo>src.zip.marco destfile=@{destfile} rootdir=@{rootdir} prefix=@{prefix} update=@{update} excludes=@{excludes}</echo>
<zip destfile="@{destfile}" update="@{update}" whenempty="skip">
<zipfileset dir="@{rootdir}" includes="@{includes}" prefix="@{prefix}" excludes="@{excludes}"></zipfileset>
<zipfileset dir="@{rootdir}" includes=".project" prefix="@{prefix}" excludes="@{excludes}"></zipfileset>
<zipfileset dir="@{rootdir}" includes="src/**" prefix="@{prefix}" excludes="@{excludes}"></zipfileset>
<zipfileset dir="@{rootdir}" includes="src-gen/**" prefix="@{prefix}" excludes="@{excludes}"></zipfileset>
</zip>
</sequential>
</macrodef>
<!-- =================================================================== -->
<!-- source tgz distribution macro -->
<!-- =================================================================== -->
<macrodef name="src.tgz.macro">
<attribute name="destfile" default=""></attribute>
<attribute name="rootdir" default="${basedir}"></attribute>
<attribute name="prefix" default=""></attribute>
<attribute name="longfile" default="gnu"></attribute>
<attribute name="excludes" default=""></attribute>
<attribute name="compression" default="gzip"></attribute>
<sequential>
<echo>src.tgz.marco destfile=@{destfile} rootdir=@{rootdir} prefix=@{prefix} update=@{update} excludes=@{excludes}</echo>
<tar destfile="@{destfile}" longfile="@{longfile}" compression="@{compression}">
<tarfileset dir="@{rootdir}" includes="*.xml,License,todo.txt,readme.txt" prefix="@{prefix}" excludes="@{excludes}"></tarfileset>
<tarfileset dir="@{rootdir}" includes=".project,.classpath" prefix="@{prefix}" excludes="@{excludes}"></tarfileset>
<tarfileset dir="@{rootdir}" includes="src/**" prefix="@{prefix}" excludes="@{excludes}"></tarfileset>
<tarfileset dir="@{rootdir}" includes="src-gen/**" prefix="@{prefix}" excludes="@{excludes}"></tarfileset>
</tar>
</sequential>
</macrodef>
<!-- =================================================================== -->
<!-- copies contents of tar to zip file -->
<!-- =================================================================== -->
<macrodef name="zip2tgz.macro">
<attribute name="src" default=""></attribute>
<attribute name="tarfile" default=""></attribute>
<attribute name="compression" default="gzip"></attribute>
<sequential>
<unzip src="@{src}" dest="${build.dir}/temp-zip"></unzip>
<tar tarfile="@{tarfile}" basedir="${build.dir}/temp-zip" compression="@{compression}"></tar>
<delete dir="${build.dir}/temp-zip"></delete>
</sequential>
</macrodef>
<!-- =================================================================== -->
<!-- copies contents of tar to zip file -->
<!-- =================================================================== -->
<macrodef name="src.dists.macro">
<attribute name="distname" default=""></attribute>
<attribute name="distdir" default="${dist.dir}"></attribute>
<attribute name="rootdir" default="${basedir}"></attribute>
<attribute name="prefix" default="@{distname}"></attribute>
<attribute name="update" default="false"></attribute>
<attribute name="excludes" default=""></attribute>
<attribute name="compression" default="gzip"></attribute>
<sequential>
<delete file="@{distdir}/@{distname}.zip" failonerror="false"></delete>
<src.zip.macro destfile="@{distdir}/@{distname}.zip" rootdir="@{rootdir}" prefix="@{prefix}" update="@{update}" excludes="@{excludes}"></src.zip.macro>
<zip2tgz.macro src="@{distdir}/@{distname}.zip" tarfile="@{distdir}/@{distname}.tgz" compression="@{compression}"></zip2tgz.macro>
</sequential>
</macrodef>
</project>