Though JavaSVN is not yet fully integrated into Subclipse as an extension, you may already try it with Subclipse. Perform the following easy steps to make Subclipse and JavaSVN work together.
<!-- <library name="svnjavahl.jar"> <export name="*"/> </library> --> <library name="javasvn.jar"> <export name="*"/> </library> <library name="jsch.jar"> <export name="*"/> </library>
Above modification will make Sublipse use JavaSVN version of JavaHL instead of native one. Jsch library is required to enable svn+ssh support. You may also download already modified plugin.xml from here.
svnClientAdapter.jar
file.-clean
command line argument to make it clean caches and use new libraries.-clean
argument is not enough and after restarting, Eclipse still uses cached libraries. In this case delete
ECLIPSE_HOME/configuration
directory and restart Eclipse.JavaSVN uses pure java JSCH library to establish SSH connection. This library supports only SSH version 2, with password or private key authentication. Using password authentication is not a problem with Subclipse, but currently it doesn't provide a way to define private key and passphrase for private key authentication. You may use the following properties to let JavaSVN know about your private key and passphrase (you need to provide these properties when starting Eclipse):
$ eclipse -vmargs -Djavasvn.ssh2.key=/path/to/private/key/file \ -Djavasvn.ssh2.passphrase=optionalPassphrase
Note: User name for ssh connection will be taken from SVN Repository properties that may be altered in Subclipse SVN Repositories view.
To avoid special batch script creation to launch Eclipse you may define ssh related properties in
Eclipse config.ini file ECLIPSE_HOME/configuration/config.ini
(tip provided by Andrew Berman):
... javasvn.ssh2.key=path/to/private/key/file javasvn.ssh2.passphrase=passphrase
In case you work with Mac OS X version of Eclipse it is not too simple to add arguments that make JSCH look for private key file at launch. Instead of command line arguments you can modify Eclipse.app/Contents/Info.plist last array of keys adding something like that (tip provided by Valentin Alekseev):
<array> ... <string>-Djavasvn.ssh2.key=/path/to/key/file</string> </array>
Step-by-step instructions:
javahl.jar
and svnClientAdapter.jar
(libraries distirbuted with the svnant) from your Ant classpath (ANT_HOME/lib/ directory).javasvn.jar
and svnClientAdapter-0.9.13.jar
files on your Ant classpath (ANT_HOME/lib/ directory).After performing the steps above svnant will use JavaSVN instead of JavaHL bindings.
If you have any questions regarding JavaSVN, would like to report a bug or contribute a patch, please write to support@tmatesoft.com