You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@maven.apache.org by hb...@apache.org on 2024/04/13 09:37:45 UTC

(maven-toolchains-plugin) 01/01: rework documentation for new JDK-specific goals

This is an automated email from the ASF dual-hosted git repository.

hboutemy pushed a commit to branch 3.2.0-doc
in repository https://gitbox.apache.org/repos/asf/maven-toolchains-plugin.git

commit 9751c3f47c516761baf992d2d57613114dee19a3
Author: Hervé Boutemy <hb...@apache.org>
AuthorDate: Sat Apr 13 11:37:33 2024 +0200

    rework documentation for new JDK-specific goals
---
 pom.xml                                                   |  2 +-
 src/site/apt/index.apt.vm                                 | 15 ++++++++-------
 .../toolchains/{discovery.apt.vm => jdk-discovery.apt.vm} |  0
 src/site/apt/toolchains/jdk.apt.vm                        |  8 ++++----
 src/site/apt/usage.apt.vm                                 |  2 +-
 src/site/site.xml                                         |  4 ++--
 6 files changed, 16 insertions(+), 15 deletions(-)

diff --git a/pom.xml b/pom.xml
index 59c0165..550511c 100644
--- a/pom.xml
+++ b/pom.xml
@@ -28,7 +28,7 @@ under the License.
   </parent>
 
   <artifactId>maven-toolchains-plugin</artifactId>
-  <version>3.1.1-SNAPSHOT</version>
+  <version>3.2.0-SNAPSHOT</version>
   <packaging>maven-plugin</packaging>
 
   <name>Apache Maven Toolchains Plugin</name>
diff --git a/src/site/apt/index.apt.vm b/src/site/apt/index.apt.vm
index 6a65a88..db8c90e 100644
--- a/src/site/apt/index.apt.vm
+++ b/src/site/apt/index.apt.vm
@@ -31,20 +31,21 @@ ${project.name}
 
 * Goals Overview
 
-  Since version 3.2.0, a new toolchains mechanism is provided.  This relies on an automatic discovery mechanism based
-  on an internal heuristic which tries to detect JDK from known locations. Read about the {{{./toolchains/discovery.html}discovery mechanism}} for more
+  Since version 3.2.0, a new JDK-specific toolchains mechanism is provided.  This relies on an automatic JDK discovery mechanism based
+  on an internal heuristic which tries to detect JDKs from known locations. Read about the {{{./toolchains/jdk-discovery.html}JDK discovery mechanism}} for more
   information. This mechanism is to be used with the goal:
 
-    * {{{./toolchain-mojo.html}toolchains:select-jdk-toolchain}} discover and selects a matching toolchain.
+    * {{{./select-jdk-toolchain-mojo.html}toolchains:select-jdk-toolchain}} discover and selects a matching toolchain.
 
-  Two helper goals are also provided:
+  Two associated helper goals are also provided:
 
-    * {{{./toolchain-mojo.html}toolchains:display-discovered-jdk-toolchains}} displays discovered toolchains to the console.
-    * {{{./toolchain-mojo.html}toolchains:generate-jdk-toolchains-xml}} can be used to write a <<<toolchains.xml>>> containing discovered JDKs.
+    * {{{./display-discovered-jdk-toolchains-mojo.html}toolchains:display-discovered-jdk-toolchains}} displays discovered toolchains to the console,
+
+    * {{{./generate-jdk-toolchains-xml-mojo.html}toolchains:generate-jdk-toolchains-xml}} can be used to generate discovered JDKs in <<<toolchains.xml>>> format and let user copy/paste.
 
   The previous <<<toolchain>>> goal is still available:
 
-    * {{{./toolchain-mojo.html}toolchains:toolchain}} selects a toolchain based on configured build requirements and stores it in build context for later retrieval by other plugins.
+    * {{{./toolchain-mojo.html}toolchains:toolchain}} selects a toolchain from <<<toolchains.xml>>> based on configured build requirements and stores it in build context for later retrieval by other plugins.
 
 * Usage
 
diff --git a/src/site/apt/toolchains/discovery.apt.vm b/src/site/apt/toolchains/jdk-discovery.apt.vm
similarity index 100%
rename from src/site/apt/toolchains/discovery.apt.vm
rename to src/site/apt/toolchains/jdk-discovery.apt.vm
diff --git a/src/site/apt/toolchains/jdk.apt.vm b/src/site/apt/toolchains/jdk.apt.vm
index 9b5a824..04f2ac1 100644
--- a/src/site/apt/toolchains/jdk.apt.vm
+++ b/src/site/apt/toolchains/jdk.apt.vm
@@ -25,7 +25,7 @@
 
 JDK Toolchain
 
-Note that this page refers to hand-written JDK toolchains.  For a simpler setup, look at the {{{./discovery.html}discovery mechanism}}.
+  Note that this page refers to hand-written JDK toolchains in <<<~/.m2/toolchains.xml>>>.  For a simpler setup, look at the {{{./jdk-discovery.html}JDK discovery mechanism}}.
 
 * Toolchain Description
 
@@ -33,16 +33,16 @@ Note that this page refers to hand-written JDK toolchains.  For a simpler setup,
  
   Predefined <<<\<provides\>>>> identification tokens, for requirement matching in plugin configuration, are:
 
-    * "<<<version>>>" marks the version of the JDK in <<<toolchain.xml>>>. In plugin's selection, this can be either a single version or a version range.
+    * "<<<version>>>" marks the version of the JDK in <<<toolchains.xml>>>. In plugin's selection, this can be either a single version or a version range.
 
     * Other tokens are accepted, but only exact matches are supported.
 
     []
 
-  There is only one <<<toolchains.xml>>> <<<\<configuration\>>>> element named "<<<jdkHome>>>". It designates the root directory
+  In <<<toolchains.xml>>>, there is only one <<<\<configuration\>>>> element named "<<<jdkHome>>>". It designates the root directory
   of a JDK installation.
 
-* Sample <<<toolchains.xml>>> setup
+* Sample <<<~/.m2/toolchains.xml>>> setup
 
 +---+
 <toolchains>
diff --git a/src/site/apt/usage.apt.vm b/src/site/apt/usage.apt.vm
index c7598b3..276ca2e 100644
--- a/src/site/apt/usage.apt.vm
+++ b/src/site/apt/usage.apt.vm
@@ -34,7 +34,7 @@ Usage
   tools (including location and other information).
 
   Maven Toolchains Plugin can read which toolchains are available on the user's
-  computer (as configured in <<<toolchains.xml>>>) and match them against the
+  computer (as configured in <<<~/.m2/toolchains.xml>>>) and match them against the
   toolchain requirements of the project (as configured in <<<pom.xml>>>). If a
   match is found, the toolchain is made available to other, <toolchain aware>,
   Maven plugins in the build.
diff --git a/src/site/site.xml b/src/site/site.xml
index 2989a7b..28f51c5 100644
--- a/src/site/site.xml
+++ b/src/site/site.xml
@@ -27,13 +27,13 @@ under the License.
       <item name="Introduction" href="index.html"/>
       <item name="Goals" href="plugin-info.html">
         <item name="toolchains:select-jdk-toolchain" href="select-jdk-toolchain-mojo.html"/>
-        <item name="toolchains:toolchain" href="toolchain-mojo.html"/>
         <item name="toolchains:display-discovered-jdk-toolchains-xml" href="display-discovered-jdk-toolchains-xml-mojo.html"/>
         <item name="toolchains:generate-jdk-toolchains-xml" href="generate-jdk-toolchains-xml-mojo.html"/>
+        <item name="toolchains:toolchain" href="toolchain-mojo.html"/>
         <item name="toolchains:help" href="help-mojo.html"/>
       </item>
       <item name="Usage" href="usage.html">
-        <item name="Discovery mechanism" href="toolchains/discovery.html"/>
+        <item name="JDK Discovery Mechanism" href="toolchains/jdk-discovery.html"/>
         <item name="Standard Toolchains" href="toolchains/index.html"/>
         <item name="JDK Standard Toolchain" href="toolchains/jdk.html"/>
         <item name="Custom Toolchains" href="toolchains/custom.html"/>