ggregory 2003/11/13 17:43:38 Modified: codec .cvsignore build.xml default.properties Log: Added an Ant target to zip/tar/gzip/checksum a distribution. Revision Changes Path 1.4 +1 -0 jakarta-commons/codec/.cvsignore Index: .cvsignore =================================================================== RCS file: /home/cvs/jakarta-commons/codec/.cvsignore,v retrieving revision 1.3 retrieving revision 1.4 diff -u -r1.3 -r1.4 --- .cvsignore 4 Oct 2003 16:27:24 -0000 1.3 +++ .cvsignore 14 Nov 2003 01:43:38 -0000 1.4 @@ -6,3 +6,4 @@ .clover .classpath .project +pub 1.11 +60 -1 jakarta-commons/codec/build.xml Index: build.xml =================================================================== RCS file: /home/cvs/jakarta-commons/codec/build.xml,v retrieving revision 1.10 retrieving revision 1.11 diff -u -r1.10 -r1.11 --- build.xml 13 Nov 2003 06:37:19 -0000 1.10 +++ build.xml 14 Nov 2003 01:43:38 -0000 1.11 @@ -49,6 +49,7 @@ <target name="clean" description="Clean build and distribution directories"> <delete dir="${build.home}"/> <delete dir="${dist.home}"/> + <delete dir="${pub.home}"/> </target> <target name="all" depends="clean,compile" description="Clean and compile all components"/> <target name="javadoc" depends="compile" description="Create component Javadoc documentation"> @@ -90,6 +91,64 @@ <include name="${final.name}.jar"/> </fileset> </copy> + </target> + <target name="pub-bin" depends="dist" description="Create binary distribution (compressed) ready for publication"> + <mkdir dir="${pub.home}"/> + <!-- Binary properties --> + <property name="final.path" value="${pub.home}/${final.name}"/> + <property name="zip.path" value="${final.path}.zip"/> + <property name="tar.path" value="${final.path}.tar"/> + <property name="gz.path" value="${tar.path}.gz"/> + <!-- Zip binary dist --> + <zip destfile="${zip.path}"> + <zipfileset dir="${dist.home}" prefix="${final.name}/"/> + </zip> + <checksum algorithm="md5" file="${zip.path}" fileext=".md5"/> + <checksum algorithm="sha" file="${zip.path}" fileext=".sha"/> + <!-- Tar & gzip binary dist --> + <tar tarfile="${tar.path}" basedir="${dist.home}"/> + <gzip zipfile="${gz.path}" src="${tar.path}"/> + <checksum algorithm="md5" file="${gz.path}" fileext=".md5"/> + <checksum algorithm="sha" file="${gz.path}" fileext=".sha"/> + <delete file="${tar.path}"/> + <!-- Delete old signatures --> + <delete file="${zip.path}.asc"/> + <delete file="${gz.path}.asc"/> + </target> + <target name="pub-src" depends="dist" description="Create source distribution (compressed) ready for publication based on your LOCAL CVS sources"> + <mkdir dir="${pub.home}"/> + <echo>Warning: The source files used to create this source distribution come from your local copy of the source files.</echo> + <!-- Source properties --> + <property name="final-src.path" value="${pub.home}/${final.name}-src"/> + <property name="zip-src.path" value="${final-src.path}.zip"/> + <property name="tar-src.path" value="${final-src.path}.tar"/> + <property name="gz-src.path" value="${tar-src.path}.gz"/> + <property name="excludes" value="${pub.home}/**, ${dist.home}/**, target/**, xdocs/**"/> + <!-- Zip source dist --> + <zip destfile="${zip-src.path}"> + <zipfileset dir="src" prefix="${final.name}/src/"/> + <zipfileset dir="." includes="build.xml" prefix="${final.name}/"/> + <zipfileset dir="." includes="checkstyle.xml" prefix="${final.name}/"/> + <zipfileset dir="." includes="default.properties" prefix="${final.name}/"/> + <zipfileset dir="." includes="LICENSE.TXT" prefix="${final.name}/"/> + <zipfileset dir="." includes="maven.xml" prefix="${final.name}/"/> + <zipfileset dir="." includes="project.properties" prefix="${final.name}/"/> + <zipfileset dir="." includes="project.xml" prefix="${final.name}/"/> + <zipfileset dir="." includes="RELEASE-NOTES.txt" prefix="${final.name}/"/> + </zip> + <checksum algorithm="md5" file="${zip-src.path}" fileext=".md5"/> + <checksum algorithm="sha" file="${zip-src.path}" fileext=".sha"/> + <!-- Tar & gzip source dist --> + <tar tarfile="${tar-src.path}" basedir="." excludes="${excludes}" excludesfile=".cvsignore"/> + <gzip zipfile="${gz-src.path}" src="${tar-src.path}"/> + <checksum algorithm="md5" file="${gz-src.path}" fileext=".md5"/> + <checksum algorithm="sha" file="${gz-src.path}" fileext=".sha"/> + <delete file="${tar-src.path}"/> + <!-- Delete old signatures --> + <delete file="${zip-src.path}.asc"/> + <delete file="${gz-src.path}.asc"/> + </target> + <target name="pub" depends="pub-bin, pub-src" description="Create binary and source distribution (compressed) ready for publication"> </target> <!-- ========== Unit Test Targets ========================================= --> <target name="compile.tests" depends="compile" description="Compile unit test cases"> 1.7 +4 -1 jakarta-commons/codec/default.properties Index: default.properties =================================================================== RCS file: /home/cvs/jakarta-commons/codec/default.properties,v retrieving revision 1.6 retrieving revision 1.7 diff -u -r1.6 -r1.7 --- default.properties 8 Nov 2003 01:52:25 -0000 1.6 +++ default.properties 14 Nov 2003 01:43:38 -0000 1.7 @@ -27,6 +27,9 @@ # The base directory for distribution targets dist.home = dist +# The base directory for distribution targets to published in compressed format +pub.home = pub + # The base directory for component sources source.home = src/java
--------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]