Ant task <sshexec> would create a new session every time.

I want to run "test -f" UNIX command for multiple files on my remote server, 
and I thought that using <sshsession>, I could just create one SSH session and 
execute all the UNIX test commands through that same session. This way I can 
avoid creating multiple SSH sessions to the remote machine. Any ideas?


Thanks
Usman Chaudhri
415-591-3031

-----Original Message-----
From: Stefan Bodewig [mailto:[email protected]] 
Sent: Wednesday, July 28, 2010 3:50 AM
To: [email protected]
Subject: Re: <sshsession> in ANT 1.8

On 2010-07-27, Rao Chaudhri wrote:

> Getting error: "CreateProcess: test -f /tmp/test.log error=2"

This is the error Windows emits if it cannot find the executable you ask
it to run.

> Here's the code, not sure what's wrong here.

>                   <sshsession ...
>                         failonerror="true">
>                         <sequential>
>                               <exec executable="test">

If you intend to run the command on the remote machine, you want to use
sshexec, not exec.

Stefan

---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]




---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to