I am writing my first Ivy configuration for any new Java project and am attempting to hook my ivy-configurations.xml file as much as my buildscript.

I have adopted all of the lessons and also have properly added the xmlns:ivy="antlib:org.apache.ivy.ant" namespace to my build.xml file. To date I have attempted running my resolve and cleancache targets, which run ivy:resolve and ivy:cleancache correspondingly, and all sorts of appears to become working (Ant will find Ivy).

However...after i run ivy:resolve, it defaults to visit to the general public repo. Since my resolvers are written to appear during my SVN root, I must conclude that Ivy doesn't see my ivy-configurations.xml file and will the general public repos automatically.

I'm intentionally keeping my ivy-configurations.xml file like a separate project in source control because it will likely be utilized by my projects.

So my question:

How do you instruct the Ant buildscipt to search for a checked-out version of ivy-configurations.xml elsewhere during my file system, not only a slave to in your area within the same directory as build.xml?

Alter the configurations file title to:


If you wish to change this default title and placement (same directory as build file) make use of the "configurations" task


This is the way I be sure that the configurations file is loaded before invoking the ivy resolve of cleancache tasks. Produce a target known as init that's declared like a dependency

<target name="init">
    <ivy:settings file="../../ivysettings.xml"/>

<target name="resolve" depends="init">

<target name="clean" description="Cleanup build directory">
    <delete dir="${build.dir}"/>

<target name="clean-all" depends="init,clean" description="Clean and purge caches">
    <!-- Purge the ivy cache -->