Let spirit guide you

thinking in life.

常用链接

统计

API

Forum

Site

WiKi

最新评论

ant creeping

#---------------
#ant.bat
#---------------
set BUILD_CP=%CLASSPATH%
set BUILD_CP=%BUILD_CP%;%JAVA_HOME%\lib\tools.jar;
set BUILD_CP=%BUILD_CP%;..\devlib\ant.jar;
set BUILD_CP=%BUILD_CP%;..\devlib\ant-junit.jar;
set BUILD_CP=%BUILD_CP%;..\devlib\ant-launcher.jar;
set BUILD_CP=%BUILD_CP%;..\devlib\junit.jar;

%JAVA_HOME%\bin\java -classpath %BUILD_CP% org.apache.tools.ant.Main -buildfile build.xml %1

#-------------
#build.xml
#-------------
  <path id="classpath">
    <pathelement location="${instrumentedclasses}"/>
    <pathelement location="${classes}"/>
    <pathelement location="${testclasses}"/>
    <pathelement location="${src}"/>
    <pathelement location="${test}"/>
    <fileset dir="${lib}" includes="**/*.jar"/>
    <fileset dir="${devlib}" includes="**/*.jar"/>
  </path>
  <target name="compile" depends="prepare">
    <javac srcdir="${src}" destdir="${classes}" deprecation="on" debug="on">
      <classpath refid="classpath"/>
    </javac>
    <javac srcdir="${test}" destdir="${testclasses}" deprecation="on" debug="on">
      <classpath refid="classpath"/>
    </javac>
  </target>
  <target name="war" depends="assemble">
    <jar jarfile="${warfile}">
      <fileset dir="${webapp}">
        <include name="**/*"/>
      </fileset>
    </jar>
  </target>



posted on 2008-06-19 00:38 cary 阅读(238) 评论(0)  编辑  收藏 所属分类: petstore


只有注册用户登录后才能发表评论。


网站导航: