ant-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Eric Fetzer <elstonk...@yahoo.com>
Subject Re: core Task 'exec' start Invalid switch - /B
Date Fri, 08 May 2009 15:17:12 GMT
Regarding the redirect to a file, PSExec has problems with redirection.  What I ended up having
to do is push a batch file to the machine, run the batch file using psexec, and then delete
the batch file when it finished.  Check out the psexec forum, it's loaded with stuff about
that:

http://forum.sysinternals.com/forum_topics.asp?FID=8

Here's one specifically:

http://forum.sysinternals.com/forum_posts.asp?TID=16830&KW=stonkers&PID=83238#83238

Regarding running from exec, I'm not sure.  I haven't used psexec at my new job so I can't
play around with it...




________________________________
From: coonay <coonay@yahoo.com>
To: user@ant.apache.org
Sent: Thursday, May 7, 2009 11:40:53 PM
Subject: core Task 'exec' start Invalid switch - /B


<target name="exec">      
      <echo message="PSEXEC is running..."/>
      
      <exec executable="start">          
        <arg line="/WAIT /B"/>                
                <arg value="psexec"/>
                <arg line=" \\${RHOST} -u ${USER} -p ${PASSWORD} ${CMD}
${ARG}"/>            
      </exec>      
      
  
</target>

/B is a valid switch for start ,but there is error using ant exec task,why
is that ?


BTW ,I want to redictor the info to a file 
<arg line=" \\${RHOST} -u ${USER} -p ${PASSWORD} ${CMD} ${ARG} >rd.log
2>&1"/>    


the & is not permited there,how can i do that ?



-----
http://coonay2010expo.blogspot.com/ http:coonay 
-- 
View this message in context: http://www.nabble.com/core-Task-%27exec%27-start--Invalid-switch----B-tp23440429p23440429.html
Sent from the Ant - Users mailing list archive at Nabble.com.


---------------------------------------------------------------------
To unsubscribe, e-mail: user-unsubscribe@ant.apache.org
For additional commands, e-mail: user-help@ant.apache.org


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