Thanks for the feedback. After playing around persistently, I got it to work.
Please see below, either of the exec tasks work now:
<target name="stat"> <exec executable="cmd"> <!--<arg value="/c cvs -f
stat | grep "Repository revision" | gawk '{print
$4 " " $3}'"/>--> <arg value="/c cvs -f stat |
grep "Repository revision" | gawk '{print $4 " " $3}'"/>
</exec> </target>
Rez> Date: Sun, 23 Nov 2008 21:11:06 +0000> From: [EMAIL PROTECTED]> To:
user@ant.apache.org> Subject: Re: Running exec tast> > 2008/11/20 Rez <[EMAIL
PROTECTED]>:> >> > Hi> >> >> > I can run the below command from a Windows cmd
line just fine> > cvs -f stat | grep "Repository revision" | gawk '{print $4 "
" $3}'> > but now I'd like to add it to my build.xml file in a target> >> >
<target name="stat"> <exec executable="cmd"> <arg value="/c"/> <arg line="cvs
-f stat | grep "Repository revision" | gawk '{print $4 " " $3}'"/>
</exec></target>> >> > I've changed the double quotes with " and single quotes
with ' and every other combination imaginable and I still get errors. Please
help.> >> > Hi,> > I think you need to experiment with redirectors[1] to see if
you can> accomplish what you're trying to do. You're trying to use shell
pipes,> which ANT doesn't know about. You need to explicitly send the output>
of one <exec/> to another one. From my reading of the manual, I think> this
should be possible.> > Cheers,> > James> > [1]
http://ant.apache.org/manual/CoreTypes/redirector.html> >
---------------------------------------------------------------------> To
unsubscribe, e-mail: [EMAIL PROTECTED]> For additional commands, e-mail: [EMAIL
PROTECTED]>
_________________________________________________________________
Color coding for safety: Windows Live Hotmail alerts you to suspicious email.
http://windowslive.com/Explore/Hotmail?ocid=TXT_TAGLM_WL_hotmail_acq_safety_112008