ant-notifications mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From maart...@apache.org
Subject svn commit: r988714 - in /ant/ivy/core/branches/2.2.x: ./ CHANGES.txt build-release.xml doc/use/publish.html ivysettings-release.xml src/java/org/apache/ivy/ant/IvyPublish.java
Date Tue, 24 Aug 2010 20:38:48 GMT
Author: maartenc
Date: Tue Aug 24 20:38:48 2010
New Revision: 988714

URL: http://svn.apache.org/viewvc?rev=988714&view=rev
Log:
Merged revisions 988691 and 988707 from trunk into 2.2.x branch.

Added:
    ant/ivy/core/branches/2.2.x/ivysettings-release.xml
      - copied unchanged from r988707, ant/ivy/core/trunk/ivysettings-release.xml
Modified:
    ant/ivy/core/branches/2.2.x/   (props changed)
    ant/ivy/core/branches/2.2.x/CHANGES.txt
    ant/ivy/core/branches/2.2.x/build-release.xml
    ant/ivy/core/branches/2.2.x/doc/use/publish.html
    ant/ivy/core/branches/2.2.x/src/java/org/apache/ivy/ant/IvyPublish.java

Propchange: ant/ivy/core/branches/2.2.x/
------------------------------------------------------------------------------
--- svn:mergeinfo (original)
+++ svn:mergeinfo Tue Aug 24 20:38:48 2010
@@ -1,4 +1,4 @@
 /ant/ivy/core/branches/2.0.0:727187-727188,727520-732505
 /ant/ivy/core/branches/2.0.0-rc2:707459-708717
 /ant/ivy/core/branches/2.0.x:696803-698317
-/ant/ivy/core/trunk:695737,696014-696031,696442,958415-958693,961017-961020,962767-983820,983827-984586,984952,988337,988678
+/ant/ivy/core/trunk:695737,696014-696031,696442,958415-958693,961017-961020,962767-983820,983827-984586,984952,988337,988678,988691-988707

Modified: ant/ivy/core/branches/2.2.x/CHANGES.txt
URL: http://svn.apache.org/viewvc/ant/ivy/core/branches/2.2.x/CHANGES.txt?rev=988714&r1=988713&r2=988714&view=diff
==============================================================================
--- ant/ivy/core/branches/2.2.x/CHANGES.txt (original)
+++ ant/ivy/core/branches/2.2.x/CHANGES.txt Tue Aug 24 20:38:48 2010
@@ -111,8 +111,10 @@ for detailed view of each issue, please 
 	
    2.2.0
 =====================================
+- DOCUMENTATION: Added missing documentation about the ivy:publish child elements.
 - DOCUMENTATION: Grammar, spelling, and clarity of Settings File documentation (IVY-1216)
(thanks to Steve Miller)
 
+- IMPROVEMENT: the <artifact> child of ivy:publish now accepts any attribute
 - IMPROVEMENT: Handle attributes in description subelements (IVY-1214) (thanks to Jean-Louis
Boudart)
 - IMPROVEMENT: Use IvyAuthenticator only when it is really necessary (IVY-1211)
 - IMPROVEMENT: MakePom task handling of mulitple artifacts for Maven2 (IVY-707) (thanks to
Jesper Pedersen)

Modified: ant/ivy/core/branches/2.2.x/build-release.xml
URL: http://svn.apache.org/viewvc/ant/ivy/core/branches/2.2.x/build-release.xml?rev=988714&r1=988713&r2=988714&view=diff
==============================================================================
--- ant/ivy/core/branches/2.2.x/build-release.xml (original)
+++ ant/ivy/core/branches/2.2.x/build-release.xml Tue Aug 24 20:38:48 2010
@@ -384,7 +384,7 @@
 	</target>
 	
 	<target name="sign" depends="init-ivy">
-		<ivy:settings id="sign.settingsId" file="ivysettings-signtask.xml" />
+		<ivy:settings id="sign.settingsId" file="ivysettings-release.xml" />
 		<ivy:cachepath organisation="org.apache.commons" settingsRef="sign.settingsId" transitive="false"
log="download-only"
 				module="commons-openpgp" revision="1.0-SNAPSHOT" inline="true" pathid="openpgp.classpath"/>
 		<ivy:cachepath organisation="org.bouncycastle" settingsRef="sign.settingsId" log="download-only"
@@ -469,6 +469,43 @@
 		</fail>
 	</target>
 	
+    <target name="upload-nexus" depends="release-version, init-ivy">
+        <ivy:settings id="upload.settingsId" file="ivysettings-release.xml" />
+        <ivy:resolve file="${basedir}/build/artifact/ivy.xml" transitive="false" />
+        <ivy:publish organisation="org.apache.ivy"
+                     module="ivy"
+                     revision="${build.version}"
+                     srcivypattern="${basedir}/build/artifact/ivy.xml"
+                     artifactspattern="${basedir}/build/distrib/maven2/[revision]/[artifact]-[revision](-[classifier]).[ext]"
+                     publishivy="false"
+                     conf="core"
+                     settingsRef="upload.settingsId"
+                     resolver="nexus">
+            <!-- The standard maven2 artifacts -->
+            <artifact name="ivy" ext="pom" type="ivy" />
+            <artifact name="ivy" ext="jar" type="sources" classifier="sources" />
+            <artifact name="ivy" ext="jar" type="javadoc" classifier="javadoc" />
+
+            <!-- The PGP signatures -->
+            <artifact name="ivy" ext="pom.asc" type="asc" />
+            <artifact name="ivy" ext="jar.asc" type="asc" />
+            <artifact name="ivy" ext="jar.asc" type="asc" classifier="sources" />
+            <artifact name="ivy" ext="jar.asc" type="asc" classifier="javadoc" />
+            
+            <!-- The SHA1 checksums -->
+            <artifact name="ivy" ext="pom.sha1" type="sha1" />
+            <artifact name="ivy" ext="jar.sha1" type="sha1" />
+            <artifact name="ivy" ext="jar.sha1" type="sha1" classifier="sources" />
+            <artifact name="ivy" ext="jar.sha1" type="sha1" classifier="javadoc" />
+            
+            <!-- The MD5 checksums -->
+            <artifact name="ivy" ext="pom.md5" type="md5" />
+            <artifact name="ivy" ext="jar.md5" type="md5" />
+            <artifact name="ivy" ext="jar.md5" type="md5" classifier="sources" />
+            <artifact name="ivy" ext="jar.md5" type="md5" classifier="javadoc" />
+        </ivy:publish>
+    </target>
+
 	<target name="prepare-snapshot" 
 	        depends="/localivy, clean-ivy-home, clean, clean-lib, snapshot-version, install,
clean-examples, coverage-report" />
 	<target name="snapshot" 

Modified: ant/ivy/core/branches/2.2.x/doc/use/publish.html
URL: http://svn.apache.org/viewvc/ant/ivy/core/branches/2.2.x/doc/use/publish.html?rev=988714&r1=988713&r2=988714&view=diff
==============================================================================
--- ant/ivy/core/branches/2.2.x/doc/use/publish.html (original)
+++ ant/ivy/core/branches/2.2.x/doc/use/publish.html Tue Aug 24 20:38:48 2010
@@ -86,14 +86,29 @@ The source artifact pattern can be speci
         <td>No. No recursive delivery is done by default</td></tr>
     <tr><td>settingsRef</td><td>A reference to the ivy settings that
must be used by this task <span class="since">(since 2.0)</span></td><td>No,
'ivy.instance' is taken by default.</td></tr></tbody>
 </table>
+<h1>Child elements</h1>
+<table class="ivy-children">
+<thead>
+    <tr><th class="ivy-chld">Element</th><th class="ivy-chld-desc">Description</th><th
class="ivy-chld-card">Cardinality</th></tr>
+</thead>
+<tbody>
+    <tr><td>artifact</td>
+        <td>Describe additional artifacts to publish<br/>These elements can have
any attribute: standard artifact attributes and (since 2.2) extra attributes are supported.</td>
+        <td>0..n</td></tr>
+    <tr><td>artifacts</td>
+        <td>Specify the pattern used to find the artifact.<br/>These elements
have a <i>pattern</i> attribute containing the pattern used to find the artifact.</td>
+        <td>0..n</td></tr>
+</tbody>
+</table>
+
 <h1>Examples</h1>
 <code type="xml">
 <ivy:publish resolver="local" pubrevision="1.0">
-   <artifacts pattern="1/[artifact].[ext]" />
-   <artifacts pattern="2/[artifact].[ext]" />
+   <artifacts pattern="build/artifacts/jars/[artifact].[ext]" />
+   <artifacts pattern="build/artifacts/zips/[artifact].[ext]" />
 </ivy:publish>
 </code>
-Publishes the last resolved module in the local resolver with revision 1.0, looking for artifacts
in directories 1 and 2.
+Publishes the last resolved module in the local resolver with revision 1.0, looking for artifacts
in directories <i>build/artifacts/jars</i> and <i>build/artifacts/zips</i>.
 	</textarea>
 <script type="text/javascript">xooki.postProcess();</script>
 </body>

Modified: ant/ivy/core/branches/2.2.x/src/java/org/apache/ivy/ant/IvyPublish.java
URL: http://svn.apache.org/viewvc/ant/ivy/core/branches/2.2.x/src/java/org/apache/ivy/ant/IvyPublish.java?rev=988714&r1=988713&r2=988714&view=diff
==============================================================================
--- ant/ivy/core/branches/2.2.x/src/java/org/apache/ivy/ant/IvyPublish.java (original)
+++ ant/ivy/core/branches/2.2.x/src/java/org/apache/ivy/ant/IvyPublish.java Tue Aug 24 20:38:48
2010
@@ -34,6 +34,7 @@ import org.apache.ivy.core.module.id.Mod
 import org.apache.ivy.core.publish.PublishOptions;
 import org.apache.ivy.core.settings.IvySettings;
 import org.apache.tools.ant.BuildException;
+import org.apache.tools.ant.DynamicAttribute;
 
 /**
  * This task allow to publish a module revision to an Ivy repository.
@@ -385,12 +386,14 @@ public class IvyPublish extends IvyTask 
         this.update = update;
     }
 
-    public class PublishArtifact implements Artifact {
+    public class PublishArtifact implements Artifact, DynamicAttribute {
         private String ext;
 
         private String name;
 
         private String type;
+        
+        private Map extra = new HashMap();
 
         public String[] getConfigurations() {
             return null;
@@ -437,36 +440,32 @@ public class IvyPublish extends IvyTask 
         }
 
         public String getAttribute(String attName) {
-            return null;
+            return (String) extra.get(attName);
         }
 
         public Map getAttributes() {
-            return new HashMap();
+            return extra;
         }
 
         public String getExtraAttribute(String attName) {
-            return null;
+            return (String) extra.get(attName);
         }
 
         public Map getExtraAttributes() {
-            return new HashMap();
+            return extra;
         }
         
         public Map getQualifiedExtraAttributes() {
-            return new HashMap();
-        }
-
-        public String getStandardAttribute(String attName) {
-            return null;
+            return extra;
         }
 
-        public Map getStandardAttributes() {
-            return new HashMap();
-        }
-        
         public boolean isMetadata() {
             return false;
         }
+        
+        public void setDynamicAttribute(String name, String value) {
+            extra.put(name, value);
+        }
     }
 
     public static class ArtifactsPattern {



Mime
View raw message