This is a fork of http://code.google.com/p/svntask/ and also takes some extra commands from https://github.com/chripo/svntask/
It is a simple wrapper around svnkit
Development on the original project has ended so this was created to provide a way of working with svn 1.7 (and above) via ant until SvnAnt is updated.
Version 1.1.1
- Added Diff task
- Bundled with svnkit-1.8.5
- Added Export task
- Bundled with svnkit-1.7.12
- bundled with svnkit-1.7.5-v1
- update Add command with fileset support (from https://github.com/chripo/svntask/)
- add svntask Auth support (from https://github.com/chripo/svntask/)
- added new commands (from https://github.com/chripo/svntask/)
- Add
- Checkout
- Commit
- Diff
- Export
- Info
- Log
- Ls
- Status
- Switch
- Update
- Cleanup
- Copy
- Delete
- Mkdir
- Unlock
Unzip the dist to a directory in your project. Unfortunately svnkit 1.7 (and above) comes with extra dependencies so it is no longer just one jar.
<path id="svnant.classpth">
<fileset dir="lib/build/svnant">
<include name="*.jar"/>
</fileset>
</path>
<taskdef name="svn" classname="com.googlecode.svntask.SvnTask" classpathref="svnant.classpth"/>
<svn username="user" password="password" >
... commands ...
</svn>
<svn>
<cleanup path="${project.src}" deleteWCProperties="false"/>
</svn>
<svn>
<copy
failOnDstExists="true"
move="false"
src="${from.file / from.url}"
dst="${to.file / to.url}"
commitMessage="copy by svntask"
/>
</svn>
<svn>
<delete
force="true"
deleteFiles="false"
includeDirs="true"
dryRun="false"
path="/path/to/delete"
/>
<delete
force="true"
deleteFiles="false"
includeDirs="true"
dryRun="false">
<fileset>
...
</fileset>
</delete>
</svn>
<target name="export">
<svn>
<export workingcopy="/path/to/workingcopy"
exportpath="/path/to/exportdir"/>
</svn>
<svn username="guest" password="">
<export url="http://host/svn/repo"
exportpath="/path/to/exportdir"/>
</svn>
</target>
<target name="diff">
<svn username="guest" password="">
<diff workingcopy="/path/to/workingcopy"
outfilename="svn.patch"/>
</svn>
</target>
<svn>
<mkdir
makeParents="true"
path="path/to/create"
commitMessage="mkdir by svntask"
/>
</svn>
<svn>
<unlock
breakLock="true"
includeDirs="true">
<fileset>
...
</fileset>
</unlock>
</svn>