File APIs for Java Developers
Manipulate DOC, XLS, PPT, PDF and many others from your application.
The moose likes Ant, Maven and Other Build Tools and the fly likes ant script for svn checkout Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login

Win a copy of REST with Spring (video course) this week in the Spring forum!
JavaRanch » Java Forums » Engineering » Ant, Maven and Other Build Tools
Bookmark "ant script for svn checkout" Watch "ant script for svn checkout" New topic

ant script for svn checkout

saam mathur

Joined: Mar 27, 2014
Posts: 1
i have written the below build script to take the checkout from svn but its not working. please help me out.

<?xml version="1.0" encoding="iso-8859-1"?>

<project name="test" basedir="." >
<path id="path.svnant">
<pathelement location="/lib/svnant.jar" />
<pathelement location="/lib/svnClientAdapter.jar" />
<pathelement location="/lib/svnjavahl.jar" />
<target name="checkout-codebase">
<property name="svn.username" value="abs"/>
<property name="svn.password" value="abs123"/>
<property name="svn.url" value="Path-to-svn-trunk-folder"/>
<property name="project.code" value="./Mbuild"/>

<typedef resource="org/tigris/subversion/svnant/svnantlib.xml" classpathref="path.svnant" />

<svnSetting svnkit="true" javahl="false" id="svn.settings" username="${svn.username}" password="${svn.password}"/>
<svn refid="svn.settings">
<checkout url="${svn.url}" revision="HEAD" destpath="${project.code}" />
Ulf Dittmer

Joined: Mar 22, 2005
Posts: 42959
Welcome to JavaRanch.

What does "not working" mean? What did you expect t happen, and what happened instead? TellTheDetails, and post any messages you have gotten as a result.

This looks wrong: classpathref="path.svnant", as does refid="svn.settings".
I agree. Here's the link:
subject: ant script for svn checkout
It's not a secret anymore!