ant-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
Subject Re: Using shell command in ANT script
Date Mon, 29 Nov 2010 06:22:06 GMT

Thanks to all of you for taking interest in my query.
I myself is in favor of solution which can be platform independent but was clueless on how
to achieve this in ANT, the shell command which I wanted to incorporate on my ANT script is
only a part of lengthy command in actual I wanted to write the content of a folder in a file
with “/*” suffix and “jobs/” as prefix to each entry, so say a directory contains
following folders
Above contents in my txt file should look like this:
And so on
So to achieve the above output I thought shell script is the best and easiest way to achieve
this and which I can make a call through my ANT script, but if I get the solution in pure
ant form then it will be great. Any thoughts?

-----Original Message-----
From: David Weintraub <>
To: Ant Users List <>
Sent: Thu, Nov 25, 2010 1:46 am
Subject: Re: Using shell command in ANT script

On Wed, Nov 24, 2010 at 12:33 PM, Ludwig, Michael> wrote:
 It's <fixcrlf>, not <fixcrnl>.

 And you could also use <pathconvert>:
Thanks for that tip of <pathconvert>. You can also use the
flattenmapper/> to remove directory names if you so choose:
        <fileset dir="../../../jobs" id="dir">
           <include name="*"/>
       <pathconvert refid="dir"
       <echo message="${dir.prop}" file="foo"/>
That should be able to replace the <exec> task.
avid Weintraub
o unsubscribe, e-mail:
or additional commands, e-mail:

  • Unnamed multipart/alternative (inline, None, 0 bytes)
View raw message