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: I need some help from you
Date Mon, 26 Jan 2009 07:01:11 GMT
AFAIK the "ls" is not an executable, it more s ahell command. Therefore the <exec> has
to execute the shell command and give the "ls" as argument.
http://ant.apache.org/faq.html#batch-shell-execute

But you could create a filelist using <pathconvert> and <echo file>.


Jan 

>-----Urspr├╝ngliche Nachricht-----
>Von: Omer Salem al-khanbushi [mailto:amri_2k@hotmail.com] 
>Gesendet: Freitag, 23. Januar 2009 20:59
>An: user@ant.apache.org; user-help@ant.apache.org
>Betreff: I need some help from you
>
>
>Hi all,
>I'm new here I need some help, I have this command under Linux 
>like this
> amri@ubuntu:~$ ls >output.txt
>
>how can I do this command using Ant (build.xml) I tried like this 
><project name="list all files">
><target name="list">
><echo message="Starting lsting files"/>
>
>    <exec executable="ls">
>      <arg line="> output.txt"/>
>    </exec>
></target>
>
>and this also
><redirector>
>        <output>
>            <property name="output.txt"/>
>        </output>
>        <error>
>            <log level="INFO"/>
>        </error>
>       </redirector>
>
></project>
>it was not work 
>
>
>could please help me
>
>Omar
>
>_________________________________________________________________
>Windows Live(tm) Hotmail®:...more than just e-mail. 
>http://windowslive.com/explore?ocid=TXT_TAGLM_WL_t2_hm_justgotb
>etter_explore_012009
>

---------------------------------------------------------------------
To unsubscribe, e-mail: user-unsubscribe@ant.apache.org
For additional commands, e-mail: user-help@ant.apache.org


Mime
View raw message