Commits

tbrugz committed bb05858 Merge

Merge

  • Participants
  • Parent commits c8fb4c9, 1cd32d6

Comments (0)

Files changed (1)

 	
 	<!-- TODO: validate-schema, all -->
 
-	<target name="config-ivy" if="ivy.settings.dir">
+	<target name="config-ivy-file" if="ivy.settings.file">
+		<echo message="setting ivy file: ${ivy.settings.file}"/>
+		<ivy:settings file="${ivy.settings.file}"/>
+	</target>
+	
+	<target name="config-ivy-dir" if="ivy.settings.dir" unless="ivy.settings.file">
+		<echo message="setting ivy file (by dir): ${ivy.settings.dir}/ivysettings.xml"/>
 		<ivy:settings file="${ivy.settings.dir}/ivysettings.xml"/>
 	</target>
+
+	<target name="config-ivy" depends="config-ivy-file,config-ivy-dir"/>
 	
 	<target name="resolve-ivy" depends="config-ivy" description="retrieve dependencies with ivy">
 		<ivy:retrieve />
 
 	<target name="publish" depends="jar,config-ivy" description="publish this project in the ivy repository">
 		<property name="revision" value="${version}"/>
-		<property name="resolver" value="local"/>
+		<property name="resolver.publish" value="local"/>
 		<ivy:info/>
-		<ivy:publish resolver="${resolver}" pubrevision="${revision}" status="release" update="true" overwrite="true">
+		<property name="ivy.pom.version" value="${revision}"/>
+		<ivy:makepom ivyfile="ivy.xml" pomfile="dist/${ivy.module}.pom"/>
+		<ivy:publish resolver="${resolver.publish}" pubrevision="${revision}" status="release" update="true" overwrite="true">
 			<artifacts pattern="${dist.dir}/[module].[ext]" />
+			<artifact name="${ivy.module}" ext="pom" type="pom" />
 		</ivy:publish>
-		<echo message="project ${ant.project.name} released with version ${revision} to ${resolver}"/>
+		<echo message="project ${ant.project.name} released with version ${revision} to ${resolver.publish}"/>
 	</target>
 
 </project>