ant-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From bugzi...@apache.org
Subject DO NOT REPLY [Bug 36302] - sshexec closes System.out
Date Thu, 08 Nov 2007 16:58:22 GMT
DO NOT REPLY TO THIS EMAIL, BUT PLEASE POST YOUR BUG·
RELATED COMMENTS THROUGH THE WEB INTERFACE AVAILABLE AT
<http://issues.apache.org/bugzilla/show_bug.cgi?id=36302>.
ANY REPLY MADE TO THIS MESSAGE WILL NOT BE COLLECTED AND·
INSERTED IN THE BUG DATABASE.

http://issues.apache.org/bugzilla/show_bug.cgi?id=36302


ghertz@libero.it changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|NEEDINFO                    |RESOLVED
         Resolution|                            |FIXED




------- Additional Comments From ghertz@libero.it  2007-11-08 08:58 -------
I've tested your suggestion and it works fine.Thanks
However, every time ssh-remote is called:

1) You have to specify the path (ie, you don't make somthing like this:
<ssh-remote command="cd ${remote.dir}"/>
<ssh-remote command="touch foo.txt"/>

The foo.txt will not create in the path ${remote.dir}", but in the $HOME of 
the remote user
To make this, I ve to do : <ssh-remote command="touch ${remote.dir}/foo.txt"/>
If I have to do another operation in the same directory, I must specify the 
path again.

2) makes a new connection with the remote machine, and I don't like this thing 
too much.
Instead, importing in the lib folder maverick-ant.jar, and using this syntax, 
I make all operations I need with one connection.

 <taskdef name="ssh" classname="com.sshtools.ant.Ssh" 
classpath="./lib/maverick-ant.jar"/>
 
       <ssh host="${remote.host}"
                username="${remote.user}"
                password="${remote.password}">
                <exec cmd="cd ${remote.commonshare}"/>
                <exec cmd="rm -rf ${codeline.dir}-OLD"/>
                <exec cmd="mv ${codeline.dir} ${codeline.dir}-OLD"/>
             <sftp action="put"
                   remotedir="${remote.commonshare}"
                   verbose="true">
                   <fileset dir="${tmp.dir}">
                        <include name="${zip.file}"/>
                   </fileset>
             </sftp>
                <exec cmd="cd ${remote.commonshare}"/>
                <exec cmd="unzip ${zip.file}"/>
                <exec cmd="rm -f ${zip.file}"/>
        </ssh>

Thanks everybody for your attention and suggestions

-- 
Configure bugmail: http://issues.apache.org/bugzilla/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug, or are watching the assignee.

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


Mime
View raw message