ant-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Buonassisi, Vincent [Contractor]" <>
Subject exec task
Date Fri, 08 Nov 2002 16:12:12 GMT

I am trying to get the exec task to create the command echo ESS.5.4.03 | sed
'...' and execute it.  Instead, it looks like the exec task is creating the
command echo "ESS.5.4.03 | sed '...'" and so what happens is that the shell
command echo just prints what is in between the double quotes.   Is it
possible to have the exec task pass the command and its arguments to the
shell as one command?  I could use ant to create a script to do this or, I
could do it using two exec tasks.   But, I was hoping that I could use just
one exec task and its arguements.

This is my target:

<target name="test1">
   <exec executable="echo" outputproperty="pkg.path.converted"
      <arg line="ESS.5.4.03 | sed 's/\./_/g'"/>
   <echo message="${pkg.path.converted}"/>

and this is the Ant result:

     [echo] ESS.5.4.03 | sed s/\./_/g

I am using ant 1.5.1 on unix.


Vincent J. Buonassisi
IT SP&A/Enterprise Reusable Components
Sprint PCS
(913) 762-9320

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