Use changing="true" on AppY's dependency on LibX. On Feb 19, 2012, at 7:46 PM, Sugar Bzzz <sugarbz...@gmail.com> wrote:
> Hello, > > I have two projects: LibX and AppY, where AppY depends on LibX. > > I would like to establish the following workflow with Ivy: > 1) make some changes to LibX > 2) rebuild and publish the modified LibX using Ant+Ivy > 3) rebuild AppY using the modified LibX > 4) repeat (goto 1) > > This works the first time around (with a clean cache) but it doesn't work a > second time. When I rebuild AppY a second time around, it uses a cached > LibX from the first iteration of this workflow. The only way I can get the > latest LibX when building AppY after publishing LibX once already, is to > clean the Ivy cache and start over; but this takes a long time since all of > the dependencies of LibX need to be redownloaded. I want AppY to use the > latest LibY that I've built. > > How can I achieve this without having to clean the Ivy cache every time I > modify LibX? > > > Thanks. > > > Here is how I have Ant and Ivy setup: > > in build.xml of LibX: > > <target name="publish" depends="jar" description="--> publish LibX"> > <ivy:publish pubrevision="${LibX.version}" resolver="local" > overwrite="true"> > <artifacts pattern="${artifacts.dir}/[artifact].[ext]"/> > </ivy:publish> > </target> > > in ivy.xml of LibX: > > <ivy-module version="2.2"> > <info organisation="myorg" module="LibX"/> > <publications> > <artifact name="LibX" type="jar"/> > </publications> > <dependencies> > <... several dependencies here ...> > </dependencies> > </ivy-module> > > in build.xml of AppY: > > <target name="resolve" description="--> retrieve dependencies"> > <ivy:retrieve/> > </target> > > in ivy.xml of AppY: > > <ivy-module version="2.2"> > <info organisation="myorg" module="AppY"/> > <dependencies> > <dependency org="myorg" name="LibX" rev="latest.integration"/> > </dependencies> > </ivy-module>