Skip to content
Closed
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
24 changes: 24 additions & 0 deletions src/main/java/org/apache/maven/plugins/deploy/DeployMojo.java
Original file line number Diff line number Diff line change
Expand Up @@ -98,6 +98,12 @@ public class DeployMojo
@Parameter( property = "altDeploymentRepository" )
private String altDeploymentRepository;

@Parameter( property = "altDeploymentRepositoryId" )
private String altDeploymentRepositoryId;

@Parameter( property = "altDeploymentRepositoryURL" )
private java.net.URL altDeploymentRepositoryURL;

/**
* The alternative repository to use when the project has a snapshot version.
*
Expand Down Expand Up @@ -148,6 +154,24 @@ public void execute()
{
failIfOffline();

if ( altDeploymentRepository == null
&& altDeploymentRepositoryURL != null
//&& altDeploymentRepositoryURL.toString().length() > 0
&& altDeploymentRepositoryId != null
//&& altDeploymentRepositoryId.length() > 0
)
{
getLog().info( "altDeploymentRepositoryId is: " + altDeploymentRepositoryId );
getLog().info( "altDeploymentRepositoryURL is: " + altDeploymentRepositoryURL );
altDeploymentRepository =
String.format( "%s::%s", altDeploymentRepositoryId, altDeploymentRepositoryURL );
getLog().info( "combined altDeploymentRepository is: " + altDeploymentRepository );
}
else
{
getLog().info( "altDeploymentRepository is: " + altDeploymentRepository );
}

// CHECKSTYLE_OFF: LineLength
// @formatter:off
ProjectDeployerRequest pdr = new ProjectDeployerRequest()
Expand Down