Maven 2.x and 3.x Deploy Plugin

Deploy should not fail if <distributionManagement> and <repository> does not exist when used with -DaltDeploymentRepository

Details

  • Type: Bug Bug
  • Status: Closed Closed
  • Priority: Major Major
  • Resolution: Duplicate
  • Affects Version/s: 2.4
  • Fix Version/s: None
  • Component/s: deploy:deploy
  • Labels:
    None
  • Number of attachments :
    0

Description

I have a pom with no <distributionManagement> section.

When I do:

mvn -DskipTests -DupdateReleaseInfo=true -DaltDeploymentRepository=ggg-deploy::default::scp://ggg/maven/maven2/deploy clean deploy

I get this error:

[INFO] Failed to configure plugin parameters for: org.apache.maven.plugins:maven-deploy-plugin:2.4

check that the following section of the pom.xml is present and correct:

<distributionManagement>
  <!-- use the following if you're not using a snapshot version. -->
  <repository>
    <id>repo</id>
    <name>Repository Name</name>
    <url>scp://host/path/to/repo</url>
  </repository>
  <!-- use the following if you ARE using a snapshot version. -->
  <snapshotRepository>
    <id>repo</id>
    <name>Repository Name</name>
    <url>scp://host/path/to/repo</url>
  </snapshotRepository>
</distributionManagement>

Cause: Class 'org.apache.maven.artifact.repository.ArtifactRepository' cannot be instantiated

However, since I supply the altDeploymentRepository parameter, it shouldn't require that section in the pom.xml

Issue Links

Activity

There are no comments yet on this issue.

People

Vote (0)
Watch (0)

Dates

  • Created:
    Updated:
    Resolved: