JRuby Rake and Ivy

Here’s a neat way of using ivy with jruby, rake & ant. task :ivy_retrieve do ant.taskdef :resource => "org/apache/ivy/ant/antlib.xml" do classpath :location => "ivy/ivy-2.2.0.jar" end ant.configure :file => "ivy/ivysettings.xml" ant.resolve :file => "ivy/ivy.xml" ant.retrieve :pattern => "lib/[conf]/[type]/[artifact]-[revision].[ext]", :sync => "true" puts end Still using ant, still angle bracket free (except for ivy, sigh). Read my previous post if you want to know more about jruby, rake and ant....

JRuby Rake Vs Ant

For the longest time I’ve been writing Java build files in XML and I’ve always felt a little dirty. Not too long ago I was re-introduced to rake by a colleague (thanks Fabio) and how nicely it integrates with ant. This means that you can now turn this: <project name="spring-conversations" default="build" basedir="."> <property name="src.dir" location="src/main" /> <property name="test.dir" location="src/test" /> <property name="build.dir" location="build" /> <property name="dist.dir" location="${build.dir}/dist" /> <property name="report.dir" location="${build....

Apache Ivy and Spring EBR

Here is how I set up the Apache Ivy dependency manager so that it can fetch springframework JARs from the SpringSource Enterprise Bundle Repository. Listing: ivysettings-custom.xml <ivysettings> <resolvers> <url name="com.springsource.repository.bundles.release"> <ivy pattern="http://repository.springsource.com/ivy/bundles/release/[organisation]/[module]/[revision]/[artifact]-[revision].[ext]" /> <artifact pattern="http://repository.springsource.com/ivy/bundles/release/[organisation]/[module]/[revision]/[artifact]-[revision].[ext]" /> </url> <url name="com.springsource.repository.bundles.external"> <ivy pattern="http://repository.springsource.com/ivy/bundles/external/[organisation]/[module]/[revision]/[artifact]-[revision].[ext]" /> <artifact pattern="http://repository.springsource.com/ivy/bundles/external/[organisation]/[module]/[revision]/[artifact]-[revision].[ext]" /> </url> <chain name="spring"> <resolver ref="com.springsource.repository.bundles.release"/> <resolver ref="com.springsource.repository.bundles.external"/> </chain> <ibiblio name="jboss" root="http://repository.jboss.org/maven2/" m2compatible="true"/> <chain name="main" dual="true"> <resolver ref="shared" /> <resolver ref="public" /> <resolver ref="spring" /> <resolver ref="jboss" /> </chain> <chain name="default" returnFirst="true"> <resolver ref="local" /> <resolver ref="main" /> </chain> </resolvers> </ivysettings> Listing: ivysettings....

svn2cvs

I am currently working with a team that uses subversion for day-to-day development but needs to use cvs due to a corporate policy. So I suggested that we create a build on our continuous integration server to automatically merge changes from a subversion working copy to a cvs checkout. I had a quick look on the internet for something to do the merging and managed to find and play with a perl script to merge from svn to cvs, and with a java application that was supposed to do the same....