pax:add-repository

Add a Maven repository element to a project

mvn pax:add-repository -DrepositoryId=... -DrepositoryURL=...

Mojo Attributes:

  • Executes as an aggregator plugin.

Required Parameters

Name Type Description
repositoryId String The repository identifier.
repositoryURL String The repository URL.

Optional Parameters

Name Type Description
overwrite boolean When true, overwrite matching entries in the POM.
pluginRepo boolean When true, treat this as a plugin repository.
releases boolean When true, enable releases from this repository. Default value is true.
snapshots boolean When true, enable snapshots from this repository.
targetDirectory File The directory containing the POM to be updated. Default value is ${project.basedir}.

Parameter Details

overwrite

When true, overwrite matching entries in the POM.

  • Type: boolean
  • Required: No
  • Expression: ${overwrite}

pluginRepo When true, treat this as a plugin repository.
  • Type: boolean
  • Required: No
  • Expression: ${pluginRepo}

releases When true, enable releases from this repository.
  • Type: boolean
  • Required: No
  • Expression: ${releases}
  • Default: true

repositoryId The repository identifier.
  • Type: java.lang.String
  • Required: Yes
  • Expression: ${repositoryId}

repositoryURL The repository URL.
  • Type: java.lang.String
  • Required: Yes
  • Expression: ${repositoryURL}

snapshots When true, enable snapshots from this repository.
  • Type: boolean
  • Required: No
  • Expression: ${snapshots}

targetDirectory The directory containing the POM to be updated.
  • Type: java.io.File
  • Required: No
  • Expression: ${targetDirectory}
  • Default: ${project.basedir}