Kai Hofmann created MDEPLOY-150: ----------------------------------- Summary: deploy-file does not use repository <url> in the same way as deploy Key: MDEPLOY-150 URL: https://jira.codehaus.org/browse/MDEPLOY-150 Project: Maven 2.x and 3.x Deploy Plugin Issue Type: Bug Components: deploy:deploy-file Affects Versions: 2.7 Environment: Windows 7, Maven 2.2.1 Reporter: Kai Hofmann Priority: Critical
We use an own lifecycle here which creates a zip file instead of a jar file. So we use <install>org.apache.maven.plugins:maven-install-plugin:install,org.apache.maven.plugins:maven-install-plugin:install-file</install> which installs the zip file correctly. Additionally I now wanted to also allow deploying of this zip file to nexus by: <deploy>org.apache.maven.plugins:maven-deploy-plugin:deploy,org.apache.maven.plugins:maven-deploy-plugin:deploy-file</deploy> in the pom I have then: <properties> <file>${project.build.directory}/${project.artifactId}-${project.version}.zip</file> </properties> <build> <pluginManagement> <plugins> <plugin> <groupId>org.apache.maven.plugins</groupId> <artifactId>maven-install-plugin</artifactId> <version>2.3.1</version> <executions> <execution> <id>install-service-zip</id> <goals> <goal>install-file</goal> </goals> </execution> </executions> </plugin> <plugin> <groupId>org.apache.maven.plugins</groupId> <artifactId>maven-deploy-plugin</artifactId> <version>2.7</version> <executions> <execution> <id>deploy-service-zip</id> <goals> <goal>deploy-file</goal> </goals> </execution> </executions> </plugin> </plugins> </pluginManagement> as well as settings for the repositories within the maven settings.xml. As said the install process works perfectly, but I have trouble with the deploy-file. When working without the deploy-file (only with the deploy) everything also works correct for the deployment. After adding the deploy-file as shown above I come into trouble, because beside the <file> property the deploy-plugin requests for the required <url> parameter. I wonder about this, because I assumed that the <url> parameter will come from the choosen repository (release vs snapshot) settings? When I set the <url> as property beside the <file> property, then I can deploy a snapshot. But to deploying snapshot/release this will not work. In deploy the url parameter is implicitly correctly choosen, why not in deploy-file? this would make the url parameter optional. So I see this as a bug/feature, because when deploy works in this way, then deploy-file should work analogous. Or have I missed something here? -- This message is automatically generated by JIRA. If you think it was sent incorrectly, please contact your JIRA administrators: https://jira.codehaus.org/secure/ContactAdministrators!default.jspa For more information on JIRA, see: http://www.atlassian.com/software/jira