maven-issues mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Omar Ahmad (JIRA)" <j...@apache.org>
Subject [jira] [Commented] (MDEPLOY-197) deploy:deploy-file in some cases upload a file twice
Date Tue, 21 Jul 2015 18:01:08 GMT

    [ https://issues.apache.org/jira/browse/MDEPLOY-197?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=14635505#comment-14635505
] 

Omar Ahmad commented on MDEPLOY-197:
------------------------------------

Hi,

Could this please be reopened? I have come across this issue in a different scenario. The
scenario I have is the following:

1. I have release artifacts inside nexus and the releases repository does not allow redeployments
of artifacts.
2. These release artifacts were not uploaded with sources and javadocs at the time of the
release.
3. I would like to upload sources and javadocs by syncing to the tag in SCM, and running the
following maven command:

mvn -e org.apache.maven.plugins:maven-source-plugin:2.4:jar org.apache.maven.plugins:maven-deploy-plugin:2.8.2:deploy-file
-Dfile=${project.build.directory}/${project.artifactId}-${project.version}-sources.jar -DrepositoryId=deployment
-Durl=http://nexus-ip:8081/nexus/content/repositories/releases -DgroupId=${project.groupId}
-DartifactId=${project.artifactId} -Dversion=${project.version} -Dclassifier=sources -Dpackaging=jar
-DgeneratePom=false

Note, I am running this against a multi module project and so hence the reason for using ${project....}
properties. 

The result of running the command above is that the sources JAR is created and uploaded successfully,
but the build fails as maven attempts to deploy the same sources JAR a second time which gets
rejected by nexus as the repository is set to not allow redeployments.

Any suggestions or thoughts? Is there another way that I could deploy sources and javadocs
to existing artifacts inside nexus?

Thanks,

Omar

> deploy:deploy-file in some cases upload a file twice
> ----------------------------------------------------
>
>                 Key: MDEPLOY-197
>                 URL: https://issues.apache.org/jira/browse/MDEPLOY-197
>             Project: Maven Deploy Plugin
>          Issue Type: Bug
>          Components: deploy:deploy-file
>    Affects Versions: 2.8.2
>            Reporter: Jeffrey Dang
>            Assignee: Robert Scholte
>            Priority: Trivial
>              Labels: easyfix
>         Attachments: added_file_check.patch
>
>   Original Estimate: 5m
>  Remaining Estimate: 5m
>
> In org/apache/maven/plugin/deploy/DeployFileMojo.java,
> When executing, deploy will be called on the file specified by deploy-file goal.
> Afterward, deploy will be called on project.getAttachedArtifacts().
> The specified deploy file can be included in the attached artifacts.



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)

Mime
View raw message