六狼论坛

 找回密码
 立即注册

QQ登录

只需一步,快速开始

新浪微博账号登陆

只需一步,快速开始

搜索
查看: 78|回复: 0

ANT study

[复制链接]

升级  45.33%

30

主题

30

主题

30

主题

秀才

Rank: 2

积分
118
 楼主| 发表于 2013-1-16 16:45:58 | 显示全部楼层 |阅读模式
Ant is a tool like "make" command in the linux.Ant is a subproject supported by apache inc.Apache Ant is a Java-based build tool. In theory, it is kind of like make, without make's wrinkles.
   Why another build tool when there is already make, gnumake, nmake, jam, and others? Because all those tools have limitations that Ant's original author couldn't live with when developing software across multiple platforms. Ant has been used successfully on many platforms, including Linux, commercial flavours of Unix such as Solaris and HP-UX, Windows NT-platforms, OS/2 Warp, Novell Netware 6, OpenVMS and MacOS X.
   Now we will study the ant build.xml properties
   
   <project name="project name" default="usage" basedir=".">
      <target name="init" depends="" >
         <echo message="......."/>
         <property name=".." value=".." />

         <delete dir="directory name .." />
         <mkdir dir="directory name.." />
         
         <javac srcdir="${sources}" destdir="${classes}" includes="jfileupload/**" source="${jdksource}" target="${jdktarget}">
             <classpath>
                <pathelement location="${sources}"/>
                ...
             </classpath>
          </javac>

          <copy todir="${classes}">
             <fileset dir=="${sources}">
                 <include name="**/*.properties"/>
                 ....
             </fileset>
          </copy>

          <unjar src="" dest=""/>
          <jar jarfile="" basedir="" />

          <move file="" todir="" overwrite="true/false" />

          <javadoc packagenames="" sourcepath="" destdir="">
             <classpath>
                 <pathelement location="${cloggingjar}"/>
                 ...
             </classpath>
          </javadoc>

          <signjar jar="" storepass="${jkspassword}" alias="${jksalias}"
           keystore="${jkskeystore}" keypass="${jkspassword}" storetype="PKCS12" />
      </target>
   </project>

   The above is the ant build.xml's knowleadge. Hope it can help you!
您需要登录后才可以回帖 登录 | 立即注册 新浪微博账号登陆

本版积分规则

快速回复 返回顶部 返回列表