Thanks! I should have thought of that. But, fyi, I had to use <arg value...> instead of <arg line...>
Thanks, -----Original Message----- From: Anakreon Mejdi [mailto:amejdi@;ertonline.gr] Sent: Friday, November 08, 2002 10:19 AM To: Ant Users List Subject: Re: exec task You should pass the params to bash or your favorite shell instead of echo. <target name="test1"> <exec executable="/bin/bash" outputproperty="pkg.path.converted" vmlauncher="false"> <arg line="echo ESS.5.4.03 | sed 's/\./_/g'"/> </exec> <echo message="${pkg.path.converted}"/> </target> Buonassisi, Vincent [Contractor] wrote: > Hi, > > 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" > vmlauncher="false"> > <arg line="ESS.5.4.03 | sed 's/\./_/g'"/> > </exec> > <echo message="${pkg.path.converted}"/> > </target> > > and this is the Ant result: > > test1: > [echo] ESS.5.4.03 | sed s/\./_/g > > I am using ant 1.5.1 on unix. > > thanks, > > Vincent J. Buonassisi > IT SP&A/Enterprise Reusable Components > Sprint PCS > (913) 762-9320 > > -- To unsubscribe, e-mail: <mailto:ant-user-unsubscribe@;jakarta.apache.org> For additional commands, e-mail: <mailto:ant-user-help@;jakarta.apache.org> -- To unsubscribe, e-mail: <mailto:ant-user-unsubscribe@;jakarta.apache.org> For additional commands, e-mail: <mailto:ant-user-help@;jakarta.apache.org>