<project default="dist" name="uptodater">
    <property name="build" value="classes"/>
    <property name="dist" value="dist"/>
    <property name="projectName" value="UpToDater"/>
    <property name="src" value="src/main"/>
    <property name="lib" value="lib"/>

    <path id="project.class.path">
        <fileset dir="${lib}" includes="*.jar"/>
    </path>

    <target name="getRevision">
        <exec executable="svn" outputproperty="version">
            <arg line="info"/>
            <redirector>
                <outputfilterchain>
                    <linecontainsregexp>
                        <regexp pattern='^Revision'/>
                    </linecontainsregexp>
                    <tokenfilter>
                        <replaceregex pattern='[\D]+([\d]+)' replace="\1"/>
                    </tokenfilter>
                </outputfilterchain>
            </redirector>
        </exec>
        <property name="uptodaterJar" value="${dist}/${projectName}-r${version}.jar"/>
    </target>

    <target name="compile" description="Compile Uptodater classes">
        <mkdir dir="${build}"/>
        <javac srcdir="${src}" destdir="${build}" debug="true">
            <classpath refid="project.class.path"/>
        </javac>
    </target>

    <target name="dist" depends="compile,getRevision" description="Build jar">
        <mkdir dir="${dist}"/>
        <jar basedir="${build}" destfile="${uptodaterJar}">
            <include name="**"/>
        </jar>
    </target>

    <target name="clean" description="Clean up">
        <delete dir="${build}"/>
        <delete dir="${dist}"/>
    </target>
</project>

<project default="dist" name="uptodater">
    <property name="build" value="classes"/>
    <property name="dist" value="dist"/>
    <property name="projectName" value="UpToDater"/>
    <property name="src" value="src/main"/>
    <property name="lib" value="lib"/>
    <property name="version" value="50"/>

    <path id="project.class.path">
        <fileset dir="${lib}" includes="*.jar"/>
    </path>

    <target name="getRevision">
        <property name="uptodaterJar" value="${dist}/${projectName}-r${version}.jar"/>
    </target>

    <target name="compile" description="Compile Uptodater classes">
        <mkdir dir="${build}"/>
        <javac srcdir="${src}" destdir="${build}" debug="true">
            <classpath refid="project.class.path"/>
        </javac>
    </target>

    <target name="dist" depends="compile,getRevision" description="Build jar">
        <mkdir dir="${dist}"/>
        <jar basedir="${build}" destfile="${uptodaterJar}">
            <include name="**"/>
        </jar>
    </target>

    <target name="clean" description="Clean up">
        <delete dir="${build}"/>
        <delete dir="${dist}"/>
    </target>
</project>

Remove svn dependency to get the version number. Use a property instead.
Remove svn dependency to get the version number. Use a property instead.
