[ 
http://jira.codehaus.org/browse/MANTTASKS-42?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Jason Dillon updated MANTTASKS-42:
----------------------------------

    Attachment: MANTTASKS-42.diff

Attached patch adds support for nested {{<attach>}} elements for deploy and 
install, suitable for use like:

{code}
<target name="test-deploy-attached" depends="initTaskDefs">
    <echo message="test" file="${basedir}/target/sample-build-test.pom.asc"/>

    <artifact:deploy file="sample-build-test.pom">
        <pom file="sample-build-test.pom" />
        <remoteRepository refid="deploy.repository" />
        <attach file="${basedir}/target/sample-build-test.pom.asc" 
type="pom.asc"/>
    </artifact:deploy>
</target>

<target name="test-install-attached" depends="initTaskDefs">
    <echo message="test" file="${basedir}/target/sample-build-test.pom.asc"/>

    <artifact:install file="sample-build-test.pom">
        <pom file="sample-build-test.pom" />
        <localRepository refid="local.repository"/>
        <attach file="${basedir}/target/sample-build-test.pom.asc" 
type="pom.asc"/>
    </artifact:install>
</target>
{code}

Adds a {{InstallDeployTaskSupport}} class to hold common code, {{InstallTask}} 
and {{DeployTask}} extend from it.

Adds a {{AttachedArtifact}} class to hold the attached artifact details (file, 
type and classifier).

To get this to build I had to change the maven artifacts to use {{2.0.6}} (and 
build the maven-2.0.6 tag of the components tree).

I updated the {{sample.build.xml}} to add {{test-install-attached}} and 
{{test-deploy-attached}} targets to test with, as well as changed the layout of 
the {{deploy.repository}} to {{default}}.

Sorry, I tried to keep close the the current style, but its not easy to make my 
fingers add all that extra whitespace, so you prolly wanna reformat the new 
bits.


> Allow install and deploy tasks to include attached artifacts
> ------------------------------------------------------------
>
>                 Key: MANTTASKS-42
>                 URL: http://jira.codehaus.org/browse/MANTTASKS-42
>             Project: Maven 2.x Ant Tasks
>          Issue Type: New Feature
>            Reporter: Jason Dillon
>         Attachments: MANTTASKS-42.diff
>
>
> The install and deploy tasks should be able to include additional artifacts 
> to _attach_ when performing install/deploy operations.

-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: 
http://jira.codehaus.org/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

Reply via email to