<?xml version="1.0" encoding="UTF-8" standalone="no"?> <project default="main" name="Create Runnable Jar for Project p4convert.dev"> <!--PROPERTIES--> <property name="main.class" value="com.perforce.svn.Main" /> <property name="integ.class" value="com.perforce.integration.IntegrationTests" /> <property name="import.class" value="com.perforce.integration.ImportTests" /> <property name="cvs_integ.class" value="com.perforce.cvs.integration.CvsIntegrationTests" /> <property name="cvs_import.class" value="com.perforce.cvs.integration.CvsImportTests" /> <property name="src.dir" value="src" /> <property name="test.dir" value="test" /> <property name="bin.dir" value="bin" /> <property name="dist.dir" value="dist" /> <property name="release.dir" value="release" /> <property name="ext.dir" value="ext" /> <property name="prop.dir" value="prop" /> <property name="jar.name" value="p4convert-svn" /> <property name="manifest.name" value="MANIFEST.MF" /> <property name="junit.dir" value="junit" /> <property name="p4java.ver" value="p4java-2013.2.858003.MAIN-TEST_ONLY-SNAPSHOT" /> <property name="version" value="ENGINEERING.BUILD.${user.name}" /> <property name="relnotedir" value="../../p4-doc/user" /> <path id="classpath"> <fileset dir="${ext.dir}"> <include name="**/*.jar" /> </fileset> </path> <!--RULE: clean project--> <target name="clean"> <delete dir="${bin.dir}" /> <delete dir="${dist.dir}" /> <delete dir="${junit.dir}" /> <delete dir="${release.dir}" /> </target> <!--RULE: check args for version string--> <target name="test-ver" unless="version"> <fail message="missing version argument: -Dversion=REL.NAME.PATCH" /> </target> <!--MANIFEST file--> <target name="manifest" depends="compile.jar"> <manifest file="${manifest.name}"> <attribute name="Main-Class" value="${main.class}" /> <attribute name="Class-Path" value="." /> <attribute name="Specification-Title" value="P4 Convert (Subversion)" /> <attribute name="Specification-Version" value="${version}" /> <attribute name="Specification-Vendor" value="Perforce Software" /> <attribute name="Implementation-Title" value="${jar.name}.jar" /> <attribute name="Implementation-Version" value="${version}" /> <attribute name="Implementation-Vendor" value="Perforce Software" /> </manifest> </target> <!--RULE: compile java source (without tests)--> <target name="compile.jar"> <mkdir dir="${bin.dir}" /> <javac srcdir="${src.dir}" destdir="${bin.dir}" classpathref="classpath" debug="true" includeantruntime="false" /> </target> <!--RULE: build release jar--> <target name="release.jar" depends="compile.jar, manifest, test-ver"> <mkdir dir="${release.dir}" /> <jar destfile="${release.dir}/${version}/${jar.name}.jar" basedir="${bin.dir}" manifest="${manifest.name}"> <fileset dir="${bin.dir}" /> <fileset dir="${prop.dir}" /> <zipfileset excludes="META-INF/*.SF" src="${ext.dir}/${p4java.ver}/${p4java.ver}.jar" /> <zipfileset excludes="META-INF/*.SF" src="${ext.dir}/icu4j-51_2.jar" /> <zipfileset excludes="META-INF/*.SF" src="${ext.dir}/slf4j-api-1.6.6.jar" /> <zipfileset excludes="META-INF/*.SF" src="${ext.dir}/slf4j-log4j12-1.6.6.jar" /> <zipfileset excludes="META-INF/*.SF" src="${ext.dir}/log4j-1.2.17.jar" /> </jar> </target> <!--RULE: build release--> <target name="release" depends="release.jar, test-ver, run"> <mkdir dir="${release.dir}/${version}" /> <copy file="p4convert-svn.html" todir="${release.dir}/${version}" /> <copy file="default.cfg" todir="${release.dir}/${version}" /> <copy file="types.map" todir="${release.dir}/${version}" /> <copy file="debug.log4j.xml" todir="${release.dir}/${version}" /> <copy file="${relnotedir}/p4convert-svnnotes.txt" todir="${release.dir}/${version}" /> <tar destfile="${release.dir}/${jar.name}.tar"> <tarfileset dir="${release.dir}/${version}/.." filemode="644"> <include name="${version}/**" /> </tarfileset> </tar> <gzip src="${release.dir}/${jar.name}.tar" destfile="${release.dir}/${jar.name}.tgz" /> <delete dir="${release.dir}/${version}" /> <delete file="${release.dir}/${jar.name}.tar" /> </target> <!--RULE: compile java source--> <target name="compile"> <mkdir dir="${bin.dir}" /> <javac srcdir="${src.dir}" destdir="${bin.dir}" classpathref="classpath" debug="true" includeantruntime="false" /> <javac srcdir="${test.dir}" destdir="${bin.dir}" classpathref="classpath" debug="true" includeantruntime="false" /> </target> <!--RULE: build jar--> <target name="jar" depends="compile, manifest"> <mkdir dir="${dist.dir}" /> <jar destfile="${dist.dir}/${jar.name}.jar" basedir="${bin.dir}" manifest="${manifest.name}"> <fileset dir="${bin.dir}" /> <fileset dir="${prop.dir}" /> <zipfileset excludes="META-INF/*.SF" src="${ext.dir}/org.junit_4.8.1.v4_8_1_v20100427-1100/junit.jar" /> <zipfileset excludes="META-INF/*.SF" src="${ext.dir}/org.hamcrest.core_1.1.0.v20090501071000.jar" /> <zipfileset excludes="META-INF/*.SF" src="${ext.dir}/${p4java.ver}/${p4java.ver}.jar" /> <zipfileset excludes="META-INF/*.SF" src="${ext.dir}/icu4j-51_2.jar" /> <zipfileset excludes="META-INF/*.SF" src="${ext.dir}/slf4j-api-1.6.6.jar" /> <zipfileset excludes="META-INF/*.SF" src="${ext.dir}/slf4j-log4j12-1.6.6.jar" /> <zipfileset excludes="META-INF/*.SF" src="${ext.dir}/log4j-1.2.17.jar" /> </jar> </target> <!--RULE: run generated jar--> <target name="run" depends="jar"> <java fork="true" classname="${main.class}"> <classpath> <path id="svn2p4.cli.id" location="${dist.dir}/${jar.name}.jar" /> </classpath> <jvmarg value="-Dfile.encoding=UTF-8" /> </java> </target> <!--RULE: run generated jar in GUI mode--> <target name="gui" depends="jar"> <java fork="true" classname="${main.class}"> <classpath> <path id="svn2p4.gui.id" location="${dist.dir}/${jar.name}.jar" /> </classpath> <jvmarg value="-Dfile.encoding=UTF-8" /> </java> </target> <!--RULE: check args for individual tests--> <target name="test-arg" unless="case"> <fail message="missing argument: -Dcase=TestName" /> </target> <!--RULE: back door tests--> <target name="back" depends="jar, test-arg"> <echo message="Running testcase: ${case}" /> <mkdir dir="${junit.dir}" /> <junit fork="yes" printsummary="yes" haltonfailure="no"> <classpath> <path id="svn2p4.test.id" location="${dist.dir}/${jar.name}.jar" /> </classpath> <jvmarg value="-Dfile.encoding=UTF-8" /> <test name="${integ.class}" methods="case${case}" todir="${junit.dir}" /> <formatter type="plain" usefile="false" /> </junit> </target> <!--RULE: front door tests--> <target name="front" depends="jar, test-arg"> <echo message="Running testcase: ${case}" /> <mkdir dir="${junit.dir}" /> <junit fork="yes" printsummary="yes" haltonfailure="no"> <classpath> <path id="svn2p4.test.id" location="${dist.dir}/${jar.name}.jar" /> </classpath> <jvmarg value="-Dfile.encoding=UTF-8" /> <test name="${import.class}" methods="case${case}" todir="${junit.dir}" /> <formatter type="plain" usefile="false" /> </junit> </target> <!--RULE: front door tests--> <target name="cvs-front" depends="jar, test-arg"> <echo message="Running testcase: ${case}" /> <mkdir dir="${junit.dir}" /> <junit fork="yes" printsummary="yes" haltonfailure="no"> <classpath> <path id="cvs2p4.test.id" location="${dist.dir}/${jar.name}.jar" /> </classpath> <jvmarg value="-Dfile.encoding=UTF-8" /> <test name="${cvs_import.class}" methods="case${case}" todir="${junit.dir}" /> <formatter type="plain" usefile="false" /> </junit> </target> <!--RULE: back door tests--> <target name="cvs-back" depends="jar, test-arg"> <echo message="Running testcase: ${case}" /> <mkdir dir="${junit.dir}" /> <junit fork="yes" printsummary="yes" haltonfailure="no"> <classpath> <path id="cvs2p4.test.id" location="${dist.dir}/${jar.name}.jar" /> </classpath> <jvmarg value="-Dfile.encoding=UTF-8" /> <test name="${cvs_integ.class}" methods="case${case}" todir="${junit.dir}" /> <formatter type="plain" usefile="false" /> </junit> </target> <!--RULE: junit tests--> <target name="junit" depends="jar"> <mkdir dir="${junit.dir}" /> <junit fork="yes" printsummary="yes" haltonfailure="no" showoutput="no" failureproperty="junit.ok"> <classpath> <path id="svn2p4.junit.id" location="${dist.dir}/${jar.name}.jar" /> </classpath> <jvmarg value="-Dfile.encoding=UTF-8" /> <test name="com.perforce.cvs.integration.CvsIntegrationTests" todir="${junit.dir}" /> <test name="com.perforce.cvs.integration.CvsImportTests" todir="${junit.dir}" /> <test name="com.perforce.integration.IntegrationTests" todir="${junit.dir}" /> <test name="com.perforce.svndump.history.TestRevisionTree" todir="${junit.dir}" /> <test name="com.perforce.svndump.parser.TestSchema" todir="${junit.dir}" /> <test name="com.perforce.svndump.prescan.TestExtractRecord" todir="${junit.dir}" /> <test name="com.perforce.svndump.prescan.TestUsage" todir="${junit.dir}" /> <test name="com.perforce.integration.ImportTests" todir="${junit.dir}" /> <formatter type="xml" /> </junit> <junitreport todir="${junit.dir}"> <fileset dir="${junit.dir}"> <include name="TEST-*.xml" /> </fileset> <report todir="${junit.dir}" /> </junitreport> <fail if="junit.ok" message="Unit test(s) failed. See reports!" /> </target> <!--RULE: default--> <target name="main" depends="jar" /> </project>
# | Change | User | Description | Committed | |
---|---|---|---|---|---|
#16 | 13920 | Paul Allen | copy part 2 (no errors) | ||
#15 | 12485 | Paul Allen | DOC: Update Markdown and build release rules for web based docs. | ||
#14 | 12481 | Paul Allen | Build: Generate a sample CVS and SVN configuration on release. | ||
#13 | 12405 | Paul Allen |
CVS: Save change list data to a JSON formatted file 'changes.json'. (Work-In-Progress) - need to add load option and resume flags |
||
#12 | 12219 | Paul Allen | Update ICU4J libs to 54_1_1 | ||
#11 | 11978 | Paul Allen | Upgrade p4java to 2014.1 | ||
#10 | 11762 | Paul Allen |
Modified the --default flag to generate default entries for the client root and server root. - Moved Main.java out of SVN package. |
||
#9 | 11299 | Paul Allen |
Updated sample debug fle for in-field debug. Use with: java -Dlog4j.configuration=file:debug.log4j.properties |
||
#8 | 11189 | Paul Allen |
Release Build: ant -Dversion="PUBLIC.Main.11188" release - minor args fix for build release rules |
||
#7 | 11186 | Paul Allen |
Support standard command line arguments. Important change please note... @rjackson @nmorse The change was needed to extend the current features like --info and --user for CVS and future SCM support. Please check the documentation and CLI usage for the new usage. - CVS support for --users - Unit tests for CLI arguments Example: standard usage. java -jar p4convert.jar --config=myFile.cfg Example: generate a CVS configuration file. java -jar p4convert.jar --type=CVS --default Example: report Subversion repository usage. java -jar p4convert.jar --type=SVN --repo=/path/to/repo.dump --info |
||
#6 | 10769 | Paul Allen |
Removed references to 'svn' from the name 'p4convert-svn'. Updated: Build, Usage, User docs, and Releases notes. |
||
#5 | 10687 | Paul Allen |
Ported ant build rules for documentation. ant docs - generates PDF document ant web - generates public html for our website |
||
#4 | 10625 | Paul Allen | Added 'tmp/' dir to ant clean rule | ||
#3 | 10493 | Paul Allen |
Added helper rules for unit tests. ant cvs - runs just the cvs front/back tests ant svn - runs just the svn front/back tests |
||
#2 | 10017 | Norman Morse | minor fixes for p4convert | ||
#1 | 9807 | Paul Allen | Initial import of p4-convert (from change 894340) |