Author: bodewig Date: Mon Feb 5 07:55:40 2007 New Revision: 503739 URL: http://svn.apache.org/viewvc?view=rev&rev=503739 Log: Add ivy.xml creation
Added: ant/antlibs/common/trunk/ivy.xml (with props) Modified: ant/antlibs/common/trunk/build.xml Modified: ant/antlibs/common/trunk/build.xml URL: http://svn.apache.org/viewvc/ant/antlibs/common/trunk/build.xml?view=diff&rev=503739&r1=503738&r2=503739 ============================================================================== --- ant/antlibs/common/trunk/build.xml (original) +++ ant/antlibs/common/trunk/build.xml Mon Feb 5 07:55:40 2007 @@ -231,6 +231,7 @@ <dirname property="common.basedir" file="${ant.file.common}"/> <import file="${common.basedir}/m2.xml"/> + <import file="${common.basedir}/ivy.xml"/> <target name="src-dist" depends="m2-pom" description="--> creates a source distribution"> Added: ant/antlibs/common/trunk/ivy.xml URL: http://svn.apache.org/viewvc/ant/antlibs/common/trunk/ivy.xml?view=auto&rev=503739 ============================================================================== --- ant/antlibs/common/trunk/ivy.xml (added) +++ ant/antlibs/common/trunk/ivy.xml Mon Feb 5 07:55:40 2007 @@ -0,0 +1,81 @@ +<?xml version="1.0"?> +<!-- + Licensed to the Apache Software Foundation (ASF) under one + or more contributor license agreements. See the NOTICE file + distributed with this work for additional information + regarding copyright ownership. The ASF licenses this file + to you under the Apache License, Version 2.0 (the + "License"); you may not use this file except in compliance + with the License. You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + + Unless required by applicable law or agreed to in writing, + software distributed under the License is distributed on an + "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY + KIND, either express or implied. See the License for the + specific language governing permissions and limitations + under the License. +--> +<project name="ivy"> + <description>Targets for ivy.xml creation/handling</description> + + <!-- ========================================================== --> + <!-- init all the Ivy support --> + <!-- ========================================================== --> + <target name="ivy-init" + depends="setup"> + <property name="ivy.organization" value="apache"/> + <property name="target.ivy.xml" + location="${build.lib}/${artifact.stub}-ivy.xml"/> + <tstamp> + <format property="publication.datetime" pattern="yyyyMMddHHmmss"/> + </tstamp> + + <!--look for a template Ivy file --> + <property name="project.ivy.xml" location="project-template.ivy.xml"/> + <available property="project.has-ivy.xml?" file="${project.ivy.xml}"/> + </target> + + + <!-- ========================================================== --> + <!-- ivy.xml creation/copy, depending on whether it exists or not --> + <!-- ========================================================== --> + + <!--copy an existing template--> + <target name="copy-ivy.xml" depends="ivy-init" if="project.has-ivy.xml?"> + <copy file="${project.ivy.xml}" tofile="${target.ivy.xml}"> + <!-- we expand ant properties here. --> + <filterchain> + <expandproperties/> + </filterchain> + </copy> + </target> + + + <!-- inline creation of a zero dependency ivy.xml. + We don't even declare a dependency on ant! + --> + <target name="make-ivy.xml" depends="ivy-init" unless="project.has-ivy.xml?"> + <echo message="Creating ivy.xml ${target.ivy.xml}" level="verbose"/> + <echoxml file="${target.ivy.xml}"> + <ivy-module version="1.3"> + <info organization="${ivy.organization}" + module="${artifact.name}" + revision="${artifact.version}" + publication="${publication.datetime}"> + <license name="Apache Software License 2.0" + url="http://www.apache.org/licenses/LICENSE-2.0"/> + <ivy-author name="Apache Ant Development Team" + url="http://ant.apache.org/"/> + </info> + </ivy-module> + </echoxml> + </target> + + <target name="ivy.xml" depends="copy-ivy.xml,make-ivy.xml"> + <checksum file="${target.ivy.xml}" algorithm="md5"/> + <checksum file="${target.ivy.xml}" algorithm="sha1"/> + </target> + +</project> \ No newline at end of file Propchange: ant/antlibs/common/trunk/ivy.xml ------------------------------------------------------------------------------ svn:eol-style = native --------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]