ant-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Jan.Mate...@rzf.fin-nrw.de
Subject AW: command line task
Date Tue, 09 Jul 2002 11:45:58 GMT
I tried the <apply>-Task:

.\build.xml
================================================
<project name="test" default="main" basedir=".">
  <target name="main">
    <apply executable="mybat.bat">
      <fileset dir="files" />
    </apply>
  </target>
</project>

.\mybat.bat
================================================
copy %1 %1.copy

.\files\
================================================
1.txt, 2.txt, 3.txt, 4.txt


The target copied all four files.


mit freundlichen Grüßen
Jan Matèrne 

RZF NRW 
Sachgebiet 314-P Methodenberatung 
Internet:	jan.materne@rzf.fin-nrw.de 



> -----Ursprüngliche Nachricht-----
> Von:	Swaminathan G [SMTP:Swaminathan_G@kaleconsultants.com]
> Gesendet am:	Dienstag, 9. Juli 2002 13:35
> An:	Ant Users List
> Betreff:	command line task
> 
> Hi,
> 
> I need to call a command line bat file with a parameter which will be a
> filename.
> I need to do this for all files in a particular directory.
> 
> how do i do this with exec ??
> 
> thnx,
> Swaminathan G.
> 
> --
> To unsubscribe, e-mail:   <mailto:ant-user-unsubscribe@jakarta.apache.org>
> For additional commands, e-mail: <mailto:ant-user-help@jakarta.apache.org>

Mime
View raw message