diff --git a/maven-site/src/site/xdoc/about.fml b/maven-site/src/site/xdoc/about.fml index 76dcb73911..96fa26bba2 100644 --- a/maven-site/src/site/xdoc/about.fml +++ b/maven-site/src/site/xdoc/about.fml @@ -38,6 +38,7 @@ with the largest Open Source projects for real-time availability of their latest releases
  • Extensible, with the ability to easily write plugins in Java or other scripting languages
  • Instant access to new features with little or no extra configuration
  • +
  • Ant tasks for dependency management and deployment outside of Maven
  • The following features are available in Maven 1.0 and will be available and much improved in Maven 2.0 through diff --git a/maven-site/src/site/xdoc/ant-tasks.xml b/maven-site/src/site/xdoc/ant-tasks.xml new file mode 100755 index 0000000000..728459a126 --- /dev/null +++ b/maven-site/src/site/xdoc/ant-tasks.xml @@ -0,0 +1,124 @@ + + + Ant Tasks for Maven 2.0 + Brett Porter + + +

    +

    + Maven 2.0 now comes with a set of Ant tasks that can be used to utilise Maven's artifact handling features + from within Ant 1.6+ or Maven 1.0+. This includes: +

    + +

    + The Ant tasks can be downloaded from the + Maven 2.0 download page. +

    + +

    + For convenience, the Ant task and all its dependencies are packaged together as a single JAR file. + While you can declare this in a classpath to pass to your own + typedef element, this guide + assumes you have installed the JAR in the + lib directory of your Ant installation. +

    +
    +
    +
    + +

    + To use the artifact tasks, assuming that the library has been installed in your Ant lib + directory, add the following namespace to your build.xml file: +

    + ]]> +
    + +

    + The main purpose of the Ant tasks is to allow you to specify dependencies inside your Ant script, for + example: +

    + + + + +]]> +

    + This will download the two dependencies given above, and additionally any dependencies they have (as long + as they have the appropriate scope). The JAR files of all of the dependencies will be added to the + Ant reference dependency.classpath, so that it can be used later, like so: +

    + ]]> +

    + You can also specify a scope parameter on each dependency. This changes the behaviour of + transitive dependencies and is useful for building different types of classpaths. To see how it affects + the behaviour of the dependencies, see the Dependency Mechanism + documentation in the Maven 2.0 site. +

    +

    + The local repository given above is optional, and defaults to ${user.home}/.m2/repository. + This is where the downloaded JAR files are stored and referenced from. +

    +
    + +

    + All of the tasks can optionally take one or more remote repositories to download from and upload to and a + local repository to store downloaded and installed archives to. +

    +

    + These can be specified inline, or if you choose to reuse them, they can be declared with an id/refid + combination. +

    + ]]> +

    + If not remote repositories are specified, the default + http://repo1.maven.org/maven2/ + is used. This is a complete copy of Ibiblio. +

    +

    + Note: to work with transitive dependencies, you must use a Maven 2.0 style repository, not a + Maven 1.0 style repository. Tools are available to convert a Maven 1.0 repository to Maven 2.0 - please + contact the mailing lists if you require this as it has not yet been formally released. +

    +

    + If your repository requires authentication, you can provide this as a nested element. It accepts the + attributes username, password, and for SSH based repositories privateKey + and passphrase. For example: +

    + ]]> +
    + +

    + If you want to share your built artifacts between projects, you can use two other tasks: install for placing + them in your local repository for access as dependencies in other scripts, and deploy for deploying + them to an remote location you have set up to serve as a repository in your organisation. +

    +

    + Please refer to the sample script for usage. +

    +
    + +

    + The file sample.build.xml + is a sample Ant script showing some of the functionality in action. +

    +
    + +

    + If you have any questions specific to the Ant tasks, please contact the Maven Users Mailing List. +

    +
    +
    + + + diff --git a/maven-site/src/site/xdoc/download.xml b/maven-site/src/site/xdoc/download.xml index 9fb6a931a8..1292b39f16 100644 --- a/maven-site/src/site/xdoc/download.xml +++ b/maven-site/src/site/xdoc/download.xml @@ -46,6 +46,19 @@ + +

    + Also available is a distribution suitable for use with Ant and Maven 1.x to use Maven 2.0's dependency + management (including transitive dependencies), repository and artifact deployment support. + See Ant Tasks for more information and installation instructions. +

    +

    Maven 2.0 is distributed under the Apache License, version 2.0. diff --git a/maven-site/src/site/xdoc/navigation.xml b/maven-site/src/site/xdoc/navigation.xml index 297716ffbf..4c35885aab 100644 --- a/maven-site/src/site/xdoc/navigation.xml +++ b/maven-site/src/site/xdoc/navigation.xml @@ -23,6 +23,7 @@ +