Yes, but there was a bug! The manual example was not working. Actually I
finally found the bug:

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

It is due to jsch 0.1.30

On 5/1/07, Martin Gainty <[EMAIL PROTECTED]> wrote:

http://ant.apache.org/manual/OptionalTasks/scp.html
<!-- copy local dir to remote dir -->
<scp todir="user:[EMAIL PROTECTED]:/home/chuck/">
    <fileset dir="src_dir"/>
  </scp>

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 -----
From: "Jean-Noël Rivasseau" <[EMAIL PROTECTED]>
To: <[EMAIL PROTECTED]>
Sent: Tuesday, May 01, 2007 9:52 AM
Subject: Probable bug found: scp task does not handle correctly
directories
containing subdirectories


> Hi, I posted this on the user list but noone answered, I have better
luck
> here.
>
> I am using Ant 1.6.5 and Ant 1.7 on Gentoo Linux amd64, and the same
> behavior appears.
>
> When using the scp task, I cannot copy a directory that contains
> subdirectories. When copying a directory that has no subdirectories,
> things
> work fine, but any directory with subdirs in it will cause the scp task
to
> hang.
>
> By hang, I mean that the scp task when Ant is loaded from the command
line
> never finishes.
>
> Should a bug report be filed? Is this normal behavior?
>
> My code:
>
>    <scp todir="[EMAIL PROTECTED] :/home/elvanor/test/" port="23"
> keyfile="${user.home}/.ssh/id_rsa" passphrase="" verbose="true">
>        <fileset dir="build/WEB-INF/classes" includes="**/*" />
>    </scp>
>
> Note that there are no errors related to authentication or whatever.
Just
> changing the fileset dir attribute to some directory that has no
> subdirectories makes the whoile thing work perfectly.
>
> Jean-Noël
>


Reply via email to