Fork me on GitHub

build-helper:remove-project-artifact

Full name:

org.codehaus.mojo:build-helper-maven-plugin:3.8.0:remove-project-artifact

Deprecated:

Removing an artifact leaves maven-metadata-local.xml listing versions that no longer exist. To remove what a build installed, give each build its own prefix in a split local repository (-Daether.enhancedLocalRepository.split -Daether.enhancedLocalRepository.localPrefix=<build>) and delete installed/<build> afterwards, or build with a separate -Dmaven.repo.local.

Description:

Remove project's artifacts from local repository. Useful to keep only one copy of large local snapshot, for example: installer, for disk space optimization purpose.

Attributes:

  • Requires a Maven project to be executed.
  • The goal is thread-safe and supports parallel builds.
  • Since version: 1.1.
  • Binds by default to the lifecycle phase: package.

Optional Parameters

Name Type Since Description
<failOnError> boolean 1.6 Whether the build fails when the directory cannot be removed. When false, a warning is logged instead.
Default: true
User Property: buildhelper.failOnError
<removeAll> boolean 1.1 When true, remove all built artifacts including all versions. When false, remove all built artifacts of this project version.
Default: true
User Property: buildhelper.removeAll

Parameter Details

<failOnError>

Whether the build fails when the directory cannot be removed. When false, a warning is logged instead.
  • Type: boolean
  • Since: 1.6
  • Required: No
  • User Property: buildhelper.failOnError
  • Default: true

<removeAll>

When true, remove all built artifacts including all versions. When false, remove all built artifacts of this project version.
  • Type: boolean
  • Since: 1.1
  • Required: No
  • User Property: buildhelper.removeAll
  • Default: true