Maven Ant Tasks
  1. Maven Ant Tasks
  2. MANTTASKS-67

artifact:deploy - The name of deploying element in snapshot repository is wrong

    Details

    • Type: Bug Bug
    • Status: Closed
    • Priority: Major Major
    • Resolution: Fixed
    • Affects Version/s: 2.0.6, 2.0.7
    • Fix Version/s: 2.0.8
    • Component/s: deploy task
    • Labels:
      None
    • Flags:
      Patch

      Description

      The zip file contains test with Ant.
      To launch it : ant test.
      I try to deploy a snapshot artifact in repository
      So, my pom.xml contains a version with the extension '-SNAPSHOT'
      And in my build file Ant i do this :
      <artifact:deploy file="lib/$

      {pom.artifactId}.jar">
      <remoteRepository url="file:./repository" />
      <pom refid="pom" />
      </artifact:deploy>

      In the repository the name of the artifact is <artifactId><version>SNAPSHOT.<packaging> instead of <artifactId><version><date>.<time><buildNumber><packaging>


      Another problem, i try to upload 2 attachments with my artifact (javadoc and java-source), and the buildNumber in the meta-data.xml increment by 3 instead of 1
      <artifact:deploy file="lib/${pom.artifactId}

      .jar">
      <remoteRepository url="file:./repository" />
      <pom refid="pom" />
      <attach file="./lib/$

      {pom.artifactId}-src.jar" type="java-source"/>
      <attach file="./lib/${pom.artifactId}

      -api.zip" type="javadoc"/>
      </artifact:deploy>
      You can test it with : ant testWithAttach

      1. MANTTASKS-67.diff
        20 kB
        Hervé Boutemy
      2. testSnapshots.zip
        1.62 MB
        David N'DIAYE

        Issue Links

          Activity

          Transition Time In Source Status Execution Times Last Executer Last Execution Date
          Open Open Closed Closed
          181d 4h 53m 1 Hervé Boutemy 18/Oct/07 16:03
          Mark Thomas made changes -
          Workflow jira [ 12953654 ] Default workflow, editable Closed status [ 12990780 ]
          Mark Thomas made changes -
          Project Import Sun Apr 05 22:08:22 UTC 2015 [ 1428271702400 ]
          Mark Thomas made changes -
          Flags Patch [ 10430 ]
          Patch Submitted Yes [ 10763 ]
          Mark Thomas made changes -
          Workflow jira [ 12716161 ] Default workflow, editable Closed status [ 12760063 ]
          Mark Thomas made changes -
          Project Import Sun Apr 05 09:00:58 UTC 2015 [ 1428224458201 ]
          Hervé Boutemy made changes -
          Resolution Fixed [ 1 ]
          Status Open [ 1 ] Closed [ 6 ]
          Hervé Boutemy made changes -
          Assignee Herve Boutemy [ hboutemy ]
          Remaining Estimate 0h [ 0 ]
          Original Estimate 0h [ 0 ]
          Description The zip file contains test with Ant.
          To launch it : ant test.

          I try to deploy a snapshot artifact in repository
          So, my pom.xml contains a version with the extension '-SNAPSHOT'
          And in my build file Ant i do this :
              <artifact:deploy file="lib/${pom.artifactId}.jar">
                 <remoteRepository url="file:./repository" />
                 <pom refid="pom" />
             </artifact:deploy>

          In the repository the name of the artifact is <artifactId>-<version>-SNAPSHOT.<packaging> instead of <artifactId>-<version>-<date>.<time>-<buildNumber>-<packaging>


          Another problem, i try to upload 2 attachments with my artifact (javadoc and java-source), and the buildNumber in the meta-data.xml increment by 3 instead of 1
              <artifact:deploy file="lib/${pom.artifactId}.jar">
                 <remoteRepository url="file:./repository" />
                 <pom refid="pom" />
                 <attach file="./lib/${pom.artifactId}-src.jar" type="java-source"/>
                 <attach file="./lib/${pom.artifactId}-api.zip" type="javadoc"/>
             </artifact:deploy>
          You can test it with : ant testWithAttach

          The zip file contains test with Ant.
          To launch it : ant test.
          I try to deploy a snapshot artifact in repository
          So, my pom.xml contains a version with the extension '-SNAPSHOT'
          And in my build file Ant i do this :
              <artifact:deploy file="lib/${pom.artifactId}.jar">
                 <remoteRepository url="file:./repository" />
                 <pom refid="pom" />
             </artifact:deploy>

          In the repository the name of the artifact is <artifactId><version>-SNAPSHOT.<packaging> instead of <artifactId><version><date>.<time><buildNumber>-<packaging>


          Another problem, i try to upload 2 attachments with my artifact (javadoc and java-source), and the buildNumber in the meta-data.xml increment by 3 instead of 1
              <artifact:deploy file="lib/${pom.artifactId}.jar">
                 <remoteRepository url="file:./repository" />
                 <pom refid="pom" />
                 <attach file="./lib/${pom.artifactId}-src.jar" type="java-source"/>
                 <attach file="./lib/${pom.artifactId}-api.zip" type="javadoc"/>
             </artifact:deploy>
          You can test it with : ant testWithAttach
          Hervé Boutemy made changes -
          Attachment MANTTASKS-67.diff [ 28624 ]
          Hervé Boutemy made changes -
          Attachment MANTTASKS-67.diff [ 28616 ]
          Hervé Boutemy made changes -
          Fix Version/s 2.0.8 [ 13618 ]
          Patch Submitted [Yes]
          Affects Version/s 2.0.7 [ 13521 ]
          Hervé Boutemy made changes -
          Attachment MANTTASKS-67.diff [ 28616 ]
          Hide
          Hervé Boutemy added a comment - - edited

          Here is a fix for the attachment numbering problem.

          For x-SNAPSHOT vs x-<date>.<time>-<buildNumber>, it's a question of supporting whether uniqueVersion="false" or uniqueVersion="true": such configuration support is a feature added in MANTTASKS-23

          Show
          Hervé Boutemy added a comment - - edited Here is a fix for the attachment numbering problem. For x-SNAPSHOT vs x-<date>.<time>-<buildNumber>, it's a question of supporting whether uniqueVersion="false" or uniqueVersion="true": such configuration support is a feature added in MANTTASKS-23
          Hervé Boutemy made changes -
          Component/s deploy task [ 12845 ]
          Hide
          David N'DIAYE added a comment -

          I haven't see the MANTTASKS-23, and i create a copy of it.

          But my case contains an Ant testCase, and i find another problem with attachment.

          Show
          David N'DIAYE added a comment - I haven't see the MANTTASKS-23 , and i create a copy of it. But my case contains an Ant testCase, and i find another problem with attachment.
          Hide
          David N'DIAYE added a comment -

          I'm sorry, it is my first jira, and i'm newby with your formatting notation.
          I can't modify my description, so i copy it in this comment with a good format :


          – The zip file contains test with Ant. To launch it : ant test.


          I try to deploy a snapshot artifact in repository
          – my pom.xml contains a version with the extension '-SNAPSHOT'
          – in my build file Ant i do this :

          <artifact:deploy file="lib/${pom.artifactId}.jar">
             <remoteRepository url="file:./repository" />
             <pom refid="pom" />
          </artifact:deploy>
          

          In the repository the name of the artifact is

          <artifactId>-<version>-SNAPSHOT.<packaging>  <!-- Wrong Format --> 

          instead of

          <artifactId>-<version>-<date>.<time>-<buildNumber>-<packaging>

          Another problem, i try to upload 2 attachments with my artifact (javadoc and java-source), and the buildNumber in the maven-metadata.xml increment by 3 instead of 1

          <artifact:deploy file="lib/${pom.artifactId}.jar">
             <remoteRepository url="file:./repository" />
             <pom refid="pom" />
             <attach file="./lib/${pom.artifactId}-src.jar" type="java-source"/>
             <attach file="./lib/${pom.artifactId}-api.zip" type="javadoc"/>
          </artifact:deploy>

          You can test it with : ant testWithAttach.

          Show
          David N'DIAYE added a comment - I'm sorry, it is my first jira, and i'm newby with your formatting notation. I can't modify my description, so i copy it in this comment with a good format : – The zip file contains test with Ant. To launch it : ant test. I try to deploy a snapshot artifact in repository – my pom.xml contains a version with the extension '-SNAPSHOT' – in my build file Ant i do this : <artifact:deploy file= "lib/${pom.artifactId}.jar" > <remoteRepository url= "file:./repository" /> <pom refid= "pom" /> </artifact:deploy> In the repository the name of the artifact is <artifactId> - <version> -SNAPSHOT. <packaging> <!-- Wrong Format --> instead of <artifactId> - <version> - <date> . <time> - <buildNumber> - <packaging> Another problem, i try to upload 2 attachments with my artifact ( javadoc and java-source ), and the buildNumber in the maven-metadata.xml increment by 3 instead of 1 <artifact:deploy file= "lib/${pom.artifactId}.jar" > <remoteRepository url= "file:./repository" /> <pom refid= "pom" /> <attach file= "./lib/${pom.artifactId}-src.jar" type= "java-source" /> <attach file= "./lib/${pom.artifactId}-api.zip" type= "javadoc" /> </artifact:deploy> You can test it with : ant testWithAttach.
          Hervé Boutemy made changes -
          Field Original Value New Value
          Link This issue duplicates MANTTASKS-23 [ MANTTASKS-23 ]
          Hide
          Hervé Boutemy added a comment -

          this seem to be a duplicate from MANTTASKS-23

          Show
          Hervé Boutemy added a comment - this seem to be a duplicate from MANTTASKS-23
          David N'DIAYE created issue -

            People

            • Assignee:
              Hervé Boutemy
              Reporter:
              David N'DIAYE
            • Votes:
              1 Vote for this issue
              Watchers:
              1 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved:

                Development