Put all of the commands in a some semblance of a shell script file (.bat)
<exec> call cmd.exe and pass the command line parameter of shell script

M-
*********************************************************************
This email message and any files transmitted with it contain confidential
information intended only for the person(s) to whom this email message is
addressed.  If you have received this email message in error, please notify
the sender immediately by telephone or email and destroy the original
message without making a copy.  Thank you.
 

 
----- Original Message -----
Sent: Thursday, July 20, 2006 5:37 PM
Subject: Re: [NAnt-users] Can't use pipe (|) within exec

Thanks for the suggestion, Chris.  But, that one didn't work for me either.
 
Erin
 

From: Chris Holt [mailto:[EMAIL PROTECTED]
Sent: Thursday, July 20, 2006 2:23 PM
To: 'Melissa Kacher'; Girardelli, Erin E; nant-users@lists.sourceforge.net
Subject: RE: [NAnt-users] Can't use pipe (|) within exec

Actually, I'm not sure that will work either.

I think you have to do this:

 

<exec program="p4.exe" commandline="label -o DevTemplate | sed -e &quot;s/DevTemplate/dev01/g&quot; | p4.exe label -i" />

 

-----Original Message-----
From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf Of Melissa Kacher
Sent: Thursday, July 20, 2006 5:15 PM
To: Girardelli, Erin E; nant-users@lists.sourceforge.net
Subject: Re: [NAnt-users] Can't use pipe (|) within exec

 

Your xml code has an illegal use of quotes.

 

Try this:

 

<exec program="p4.exe" commandline='label -o DevTemplate | sed -e

"s/DevTemplate/dev01/g" | p4.exe label -I' />

 

 

Thanks,

Melissa

 

 

-----Original Message-----

From: [EMAIL PROTECTED]

[mailto:[EMAIL PROTECTED] On Behalf Of

Girardelli, Erin E

Sent: Thursday, July 20, 2006 2:09 PM

To: nant-users@lists.sourceforge.net

Subject: [NAnt-users] Can't use pipe (|) within exec

 

Hi,

 

When I try to use a pipe or redirecting arrow in the exec task, I get a

failure saying the program I executed has the wrong number of arguments.

Here's what it looks like within my script:

 

      <exec program="p4.exe" commandline="label -o DevTemplate | sed

-e "s/DevTemplate/dev01/g" | p4.exe label -i" />

 

I get the same failure no matter what program I am using; it isn't

unique to my "p4.exe" program.  If I type the following into a command

prompt, everything works just fine:

 

      p4 label -o DevTemplate | sed -e "s/DevTemplate/dev01/g" | p4

label -i

 

So, how can I translate the above line into NAnt without resorting to a

batch file?

 

Thank you,

Erin

 

 

------------------------------------------------------------------------

-

Take Surveys. Earn Cash. Influence the Future of IT

Join SourceForge.net's Techsay panel and you'll get the chance to share

your

opinions on IT & business topics through brief surveys -- and earn cash

http://www.techsay.com/default.php?page=join.php&p=sourceforge&CID=DEVDE

V

_______________________________________________

NAnt-users mailing list

NAnt-users@lists.sourceforge.net

https://lists.sourceforge.net/lists/listinfo/nant-users

 

-------------------------------------------------------------------------

Take Surveys. Earn Cash. Influence the Future of IT

Join SourceForge.net's Techsay panel and you'll get the chance to share your

opinions on IT & business topics through brief surveys -- and earn cash

http://www.techsay.com/default.php?page=join.php&p=sourceforge&CID=DEVDEV

_______________________________________________

NAnt-users mailing list

NAnt-users@lists.sourceforge.net

https://lists.sourceforge.net/lists/listinfo/nant-users


-------------------------------------------------------------------------
Take Surveys. Earn Cash. Influence the Future of IT
Join SourceForge.net's Techsay panel and you'll get the chance to share your
opinions on IT & business topics through brief surveys -- and earn cash
http://www.techsay.com/default.php?page=join.php&p=sourceforge&CID=DEVDEV


_______________________________________________
NAnt-users mailing list
NAnt-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/nant-users
-------------------------------------------------------------------------
Take Surveys. Earn Cash. Influence the Future of IT
Join SourceForge.net's Techsay panel and you'll get the chance to share your
opinions on IT & business topics through brief surveys -- and earn cash
http://www.techsay.com/default.php?page=join.php&p=sourceforge&CID=DEVDEV
_______________________________________________
NAnt-users mailing list
NAnt-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/nant-users

Reply via email to