deploy:deploy-file

Full name:

org.apache.maven.plugins:maven-deploy-plugin:2.7:deploy-file

Description:

Installs the artifact in the remote repository.

Attributes:

  • The goal is thread-safe and supports parallel builds.

Required Parameters

Name Type Since Description
file File - File to be deployed.
repositoryId String - Server Id to map on the <id> under <server> section of settings.xml In most cases, this parameter will be required for authentication.
Default value is: remote-repository.
url String - URL where the artifact will be deployed.
ie ( file:///C:/m2-repo or scp://host.com/path/to/repo )

Optional Parameters

Name Type Since Description
artifactId String - ArtifactId of the artifact to be deployed. Retrieved from POM file if specified.
classifier String - Add classifier to the artifact
classifiers String - A comma separated list of classifiers for each of the extra side artifacts to deploy. If there is a mis-match in the number of entries in files or types, then an error will be raised.
description String - Description passed to a generated POM file (in case of generatePom=true)
files String - A comma separated list of files for each of the extra side artifacts to deploy. If there is a mis-match in the number of entries in types or classifiers, then an error will be raised.
generatePom boolean - Upload a POM for this artifact. Will generate a default POM if none is supplied with the pomFile argument.
Default value is: true.
groupId String - GroupId of the artifact to be deployed. Retrieved from POM file if specified.
javadoc File 2.6 The bundled API docs for the artifact.
packaging String - Type of the artifact to be deployed. Retrieved from the <packaging> element of the POM file if a POM file specified. Defaults to the file extension if it is not specified via command line or POM.
Maven uses two terms to refer to this datum: the <packaging> element for the entire POM, and the <type> element in a dependency specification.
pomFile File - Location of an existing POM file to be deployed alongside the main artifact, given by the ${file} parameter.
repositoryLayout String - The type of remote repository layout to deploy to. Try legacy for a Maven 1.x-style repository layout.
Default value is: default.
retryFailedDeploymentCount int 2.7 Parameter used to control how many times a failed deployment will be retried before giving up and failing. If a value outside the range 1-10 is specified it will be pulled to the nearest value within the range 1-10.
Default value is: 1.
sources File 2.6 The bundled sources for the artifact.
types String - A comma separated list of types for each of the extra side artifacts to deploy. If there is a mis-match in the number of entries in files or classifiers, then an error will be raised.
uniqueVersion boolean - Whether to deploy snapshots with a unique version or not.
Default value is: true.
updateReleaseInfo boolean - Parameter used to update the metadata to make the artifact as release.
Default value is: false.
version String - Version of the artifact to be deployed. Retrieved from POM file if specified.

Parameter Details

artifactId:

ArtifactId of the artifact to be deployed. Retrieved from POM file if specified.
  • Type: java.lang.String
  • Required: No
  • Expression: ${artifactId}

classifier:

Add classifier to the artifact
  • Type: java.lang.String
  • Required: No
  • Expression: ${classifier}

classifiers:

A comma separated list of classifiers for each of the extra side artifacts to deploy. If there is a mis-match in the number of entries in files or types, then an error will be raised.
  • Type: java.lang.String
  • Required: No
  • Expression: ${classifiers}

description:

Description passed to a generated POM file (in case of generatePom=true)
  • Type: java.lang.String
  • Required: No
  • Expression: ${generatePom.description}

file:

File to be deployed.
  • Type: java.io.File
  • Required: Yes
  • Expression: ${file}

files:

A comma separated list of files for each of the extra side artifacts to deploy. If there is a mis-match in the number of entries in types or classifiers, then an error will be raised.
  • Type: java.lang.String
  • Required: No
  • Expression: ${files}

generatePom:

Upload a POM for this artifact. Will generate a default POM if none is supplied with the pomFile argument.
  • Type: boolean
  • Required: No
  • Expression: ${generatePom}
  • Default: true

groupId:

GroupId of the artifact to be deployed. Retrieved from POM file if specified.
  • Type: java.lang.String
  • Required: No
  • Expression: ${groupId}

javadoc:

The bundled API docs for the artifact.
  • Type: java.io.File
  • Since: 2.6
  • Required: No
  • Expression: ${javadoc}

packaging:

Type of the artifact to be deployed. Retrieved from the <packaging> element of the POM file if a POM file specified. Defaults to the file extension if it is not specified via command line or POM.
Maven uses two terms to refer to this datum: the <packaging> element for the entire POM, and the <type> element in a dependency specification.
  • Type: java.lang.String
  • Required: No
  • Expression: ${packaging}

pomFile:

Location of an existing POM file to be deployed alongside the main artifact, given by the ${file} parameter.
  • Type: java.io.File
  • Required: No
  • Expression: ${pomFile}

repositoryId:

Server Id to map on the <id> under <server> section of settings.xml In most cases, this parameter will be required for authentication.
  • Type: java.lang.String
  • Required: Yes
  • Expression: ${repositoryId}
  • Default: remote-repository

repositoryLayout:

The type of remote repository layout to deploy to. Try legacy for a Maven 1.x-style repository layout.
  • Type: java.lang.String
  • Required: No
  • Expression: ${repositoryLayout}
  • Default: default

retryFailedDeploymentCount:

Parameter used to control how many times a failed deployment will be retried before giving up and failing. If a value outside the range 1-10 is specified it will be pulled to the nearest value within the range 1-10.
  • Type: int
  • Since: 2.7
  • Required: No
  • Expression: ${retryFailedDeploymentCount}
  • Default: 1

sources:

The bundled sources for the artifact.
  • Type: java.io.File
  • Since: 2.6
  • Required: No
  • Expression: ${sources}

types:

A comma separated list of types for each of the extra side artifacts to deploy. If there is a mis-match in the number of entries in files or classifiers, then an error will be raised.
  • Type: java.lang.String
  • Required: No
  • Expression: ${types}

uniqueVersion:

Whether to deploy snapshots with a unique version or not.
  • Type: boolean
  • Required: No
  • Expression: ${uniqueVersion}
  • Default: true

updateReleaseInfo:

Parameter used to update the metadata to make the artifact as release.
  • Type: boolean
  • Required: No
  • Expression: ${updateReleaseInfo}
  • Default: false

url:

URL where the artifact will be deployed.
ie ( file:///C:/m2-repo or scp://host.com/path/to/repo )
  • Type: java.lang.String
  • Required: Yes
  • Expression: ${url}

version:

Version of the artifact to be deployed. Retrieved from POM file if specified.
  • Type: java.lang.String
  • Required: No
  • Expression: ${version}