`

ant判断文件是否存在

    博客分类:
  • ant
 
阅读更多

 <?xml version="1.0" encoding="UTF-8" ?>   

<project name="unzip" default="unzip" basedir=".">  

 <target name="unzip">  

  <available file="archiva.xml" property="archiva.exist" />   

  <echo>${archiva.exist}</echo>     

  </target>  

  </project> 

 

运行:
E:\automatize>ant -buildfile build2.xml
Buildfile: E:\automatize\build2.xml

unzip:
     [echo] true

BUILD SUCCESSFUL
Total time: 0 seconds

分享到:
评论

相关推荐

Global site tag (gtag.js) - Google Analytics