ant-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From serdsch <>
Subject Re: how to define task sshexec
Date Tue, 12 Feb 2008 08:55:40 GMT

Hi Peter,

> No quite non-existent:

Yeah, OK, there is this little bit of documentation from Ant which only
tells you how to use the task from inside Ant. I wouldn't really expect more
from Ant, but the documentation of jcraft is really non-existent, isn't it? 

Anyway, thanx a lot for your answer, it really helped. It gave me some
ideas, so I tried and looked around inside the .jars and found the solution.
I am not using a full ant distribution but only the ant-launcher and its
necessary .jars, so I dont have a ant/lib folder. What I did now was to add
'-lib ${path-to-jsch-0.1.37.jar}' in the bat-file calling Ant, but it still
couldn't find the *.sshexec-class. This one is found in the ant-jsch.jar
that comes with your Ant distribution. 

So for anyone facing the same problem, what you need is the following:

1) jsch-0.1.37.jar from jcraft
2) ant-jsch.jar from ant
3) put them both in some folder ${path-to-my-ant} where ever you like
4) define the task in your buildfile as the following:

<taskdef name="sshexec"

5) when calling Ant, set a command line property '-lib ${path-to-my-ant}'

And everything works just fine...

Cheers, Sergio
View this message in context:
Sent from the Ant - Users mailing list archive at

To unsubscribe, e-mail:
For additional commands, e-mail:

View raw message