ant:run

Full name:

org.kuali.maven.plugins:ant-maven-plugin:1.0.6-SNAPSHOT:run

Description:

Maven Ant Mojo. Allows Maven to invoke a target inside an Ant build file. The build file can be located on the file system, the ant-maven-plugin classpath, or any resource URL that Spring 3.0 can understand.

By default, this mojo makes the following available to Ant build files as both properties and references:

maven.compile.classpath=The classpath Maven is using for compilation
maven.runtime.classpath=The classpath Maven is using at runtime
maven.test.classpath=The classpath Maven is using for testing
maven.plugin.classpath=The classpath for the ant-maven-plugin

These are available as Ant references:

maven.project=MavenProject
maven.project.helper=MavenProjectHelper
maven.local.repository=ArtifactRepository

Attributes:

  • Requires a Maven project to be executed.
  • Requires dependency resolution of artifacts in scope: test.
  • The goal is thread-safe and supports parallel builds.

Required Parameters

Name Type Since Description
file String - The build file to use. This supports Spring 3.0 resource URL expressions eg "classpath:build.xml" or "http://myurl/build.xml". The ant-maven-plugin classpath is what is searched when using the "classpath:" notation
Default value is: build.xml.

Optional Parameters

Name Type Since Description
customTaskPrefix String - The xml tag prefix to use for the built in Ant tasks. This prefix needs to be prepended to each task referenced. For example, a prefix of "mvn" means that the attachartifact task is referenced by "<mvn:attachartifact>" The default value of an empty string means that no prefix is used for the tasks.
exportAntProperties boolean - Specifies whether the Ant properties should be propagated to the Maven properties.
Default value is: false.
failOnError boolean - Specifies whether a failure in the ant build leads to a failure of the Maven build. If this value is 'false', the Maven build will proceed even if the ant build fails. If it is 'true', then the Maven build fails if the ant build fails.
Default value is: true.
inheritAll String - If true, pass all Maven properties to Ant
Default value is: true.
inheritRefs String - If true, pass Maven object references to Ant (MavenProject, MavenProjectHelper, ArtifactRepository - for the local repo)
Default value is: true.
output String - Filename to redirect the ant output to. This is relative to the base directory of the current project
propertyPrefix String - String to prepend to project and dependency property names.
skip boolean - Specifies whether the Antrun execution should be skipped.
Default value is: false.
target String - The target inside the build file to invoke. If not provided, the default target from the specified build file will be executed

Parameter Details

customTaskPrefix:

The xml tag prefix to use for the built in Ant tasks. This prefix needs to be prepended to each task referenced. For example, a prefix of "mvn" means that the attachartifact task is referenced by "<mvn:attachartifact>" The default value of an empty string means that no prefix is used for the tasks.
  • Type: java.lang.String
  • Required: No
  • Expression: ${ant.customTaskPrefix}

exportAntProperties:

Specifies whether the Ant properties should be propagated to the Maven properties.
  • Type: boolean
  • Required: No
  • Expression: ${ant.exportAntProperties}
  • Default: false

failOnError:

Specifies whether a failure in the ant build leads to a failure of the Maven build. If this value is 'false', the Maven build will proceed even if the ant build fails. If it is 'true', then the Maven build fails if the ant build fails.
  • Type: boolean
  • Required: No
  • Expression: ${ant.failOnError}
  • Default: true

file:

The build file to use. This supports Spring 3.0 resource URL expressions eg "classpath:build.xml" or "http://myurl/build.xml". The ant-maven-plugin classpath is what is searched when using the "classpath:" notation
  • Type: java.lang.String
  • Required: Yes
  • Expression: ${ant.file}
  • Default: build.xml

inheritAll:

If true, pass all Maven properties to Ant
  • Type: java.lang.String
  • Required: No
  • Expression: ${ant.inheritAll}
  • Default: true

inheritRefs:

If true, pass Maven object references to Ant (MavenProject, MavenProjectHelper, ArtifactRepository - for the local repo)
  • Type: java.lang.String
  • Required: No
  • Expression: ${ant.inheritRefs}
  • Default: true

output:

Filename to redirect the ant output to. This is relative to the base directory of the current project
  • Type: java.lang.String
  • Required: No
  • Expression: ${ant.output}

propertyPrefix:

String to prepend to project and dependency property names.
  • Type: java.lang.String
  • Required: No
  • Expression: ${ant.propertyPrefix}

skip:

Specifies whether the Antrun execution should be skipped.
  • Type: boolean
  • Required: No
  • Expression: ${ant.skip}
  • Default: false

target:

The target inside the build file to invoke. If not provided, the default target from the specified build file will be executed
  • Type: java.lang.String
  • Required: No
  • Expression: ${ant.target}