ant-ivy-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Bagwell, Allen F" <>
Subject checking before publishing
Date Tue, 17 Apr 2007 13:43:13 GMT
Hi, I'm an Ivy newbie so please bear with me.  I've done the tutorials up through "multi-project".

I've been successful at getting Ivy to publish a library to a shared repository on our system.
 But following the tutorial, it creates a new version every single time when the publish target
is run. I'd like to be able to get Ivy to recognize that an artifact doesn't need to be published
if it is that same as the last revision.  I've been struggling with trying to figure that

Here's what I have so far:

(in the config dir)

	<settings defaultResolver="my-artifacts" />
		<filesystem name="my-artifacts" checkmodified="true" >
			<ivy pattern="${repos.root}/[organisation]/[module]/ivys/ivy-[revision].xml" />
			<artifact pattern="${repos.root}/[organisation]/[module]/[type]/[revision]/[artifact].[ext]"
		<module organisation="myorg" name="math_lib" resolver="my-artifacts" />
(in ivy.xml)

<ivy-module version="1.3">

    <info organisation="myorg" module="math_lib" status="integration" />
    <configurations defaultconfmapping="default">
		<conf name="master" description="the compiled artifact" />
		<conf name="default" extends="master" />

    	<artifact name="libMath" type="static" ext="a" conf="*" />


(in the ant build.xml file)

	<!-- =================================
	      target: publish (ivy)
	    ================================= -->
	<target name="publish" depends="resolve,build" description="--> publish this project
in the ivy repository">
		<delete file="${cpp.dir.src}/ivy.xml" />
		<ivy:buildnumber organisation="myorg" module="math_lib" revision="3.5.0"/>
		<property name="revision" value="${}"/>
		<ivy:publish artifactspattern="${cpp.dir.src}/[artifact].[ext]"
				pubrevision="${revision}" />
		<echo message="project ${} released with version ${revision}" />
    <!-- =================================
          target: resolve
         ================================= -->
    <target name="resolve" description="--> retreive dependencies with ivy">
		<ivy:configure file="config/ivysettings.xml" />
        <ivy:resolve />

This set up does the following whenever publish is run:


Where libMath.a ends up being the same executable in the ivy repos (confirmed by looking at
value of each libMath.a.md5).  How can I get it so that a new revision is produced only if
the .a file is different?

Any help is greatly appreciated.
-Allen Bagwell

  • Unnamed multipart/alternative (inline, None, 0 bytes)
View raw message