Modified: maven/website/content/faq-unoffical.html ============================================================================== --- maven/website/content/faq-unoffical.html (original) +++ maven/website/content/faq-unoffical.html Sat Aug 20 12:41:42 2022 @@ -2,15 +2,15 @@ <!-- - | Generated by Apache Maven Doxia Site Renderer 1.11.1 from content/markdown/faq-unoffical.md at 2022-08-20 + | Generated by Apache Maven Doxia Site Renderer 2.0.0-M3 from content/markdown/faq-unoffical.md at 2022-08-20 | Rendered using Apache Maven Fluido Skin 1.11.0 --> <html xmlns="http://www.w3.org/1999/xhtml" lang="en"> <head> <meta charset="UTF-8" /> <meta name="viewport" content="width=device-width, initial-scale=1" /> - <meta name="generator" content="Apache Maven Doxia Site Renderer 1.11.1" /> - <title>Maven – </title> + <meta name="generator" content="Apache Maven Doxia Site Renderer 2.0.0-M3" /> + <title>Maven</title> <link rel="stylesheet" href="./css/apache-maven-fluido-1.11.0.min.css" /> <link rel="stylesheet" href="./css/site.css" /> <link rel="stylesheet" href="./css/print.css" media="print" /> @@ -46,7 +46,7 @@ <ul class="breadcrumb"> <li class=""><a href="https://www.apache.org/" class="externalLink" title="Apache">Apache</a><span class="divider">/</span></li> <li class=""><a href="index.html" title="Maven">Maven</a><span class="divider">/</span></li> - <li class="active "> <a href="https://github.com/apache/maven-site/tree/master/content/markdown/faq-unoffical.md"><img src="./images/accessories-text-editor.png" title="Edit" /></a></li> + <li class="active ">Maven <a href="https://github.com/apache/maven-site/tree/master/content/markdown/faq-unoffical.md"><img src="./images/accessories-text-editor.png" title="Edit" /></a></li> <li id="publishDate" class="pull-right"><span class="divider">|</span> Last Published: 2022-08-20</li> <li class="pull-right"><span class="divider">|</span> <a href="scm.html" title="Get Sources">Get Sources</a></li> @@ -139,10 +139,10 @@ KIND, either express or implied. See th specific language governing permissions and limitations under the License. --> -<p><i>NOTE:</i> <i>This page contains drafts of user contributed FAQ entries. The content you see here might not be fully fool-proof or might not comply with the best practices promoted by Maven. What is only guaranteed is that they have worked once for some members. It is best to treat these items as “works in progress” until they have been reviewed and promoted to the main Maven documentation site.</i></p> +<p><em>NOTE:</em> <em>This page contains drafts of user contributed FAQ entries. The content you see here might not be fully fool-proof or might not comply with the best practices promoted by Maven. What is only guaranteed is that they have worked once for some members. It is best to treat these items as works in progress until they have been reviewed and promoted to the main Maven documentation site.</em></p> <p>Please follow the format that is being used because it will help in our automated extraction of material which can then be incorporated into the main site.</p> -<p>This page serves as a collection of questions <i>with</i> answers. If you have a frequently asked question that doesn't yet have an answer, please list that question on [the other page](FAQs].</p> -<h1>Answered Questions (Index)</h1><section><section> +<p>This page serves as a collection of questions <em>with</em> answers. If you have a frequently asked question that doesn't yet have an answer, please list that question on [the other page](FAQs].</p><section> +<h1><a name="Answered_Questions_.28Index.29"></a>Answered Questions (Index)</h1><section><section> <h3><a name="Reports_.26_Site_Docs"></a>Reports & Site Docs</h3> <p>[How do I merge a list of configuration items in a parent POM with those in a child POM?](#How do I merge a list of configuration items in a parent POM with those in a child POM?) [Why do I not get an index.html page generated for my project website?](#Why do I not get an index.html page generated for my project website?) @@ -171,7 +171,7 @@ under the License. [I've just created a maven plugin. Is there a sample plugin integration test I can use?](#I've just created a maven plugin. Is there a sample plugin integration test I can use?] [The snapshot version of the plugin is not updated in the snapshot repo, What should I do to update my copy of the plugin?](#The snapshot version of the plugin is not updated in the snapshot repo, What should I do to update my copy of the plugin?] [How to list all goals available for a certain plugin?](#How to list all goals available for a certain plugin?] -[What does the ‘You cannot have two plugin executions with the same (or missing) elements’ message mean?](#What does the ‘You cannot have two plugin executions with the same (or missing) elements’ message mean?] +[What does the You cannot have two plugin executions with the same (or missing) elements message mean?](#What does the You cannot have two plugin executions with the same (or missing) elements message mean?] [#How do I execute the assembly plugin with different configurations] [Where is the plugin-registry.xml?](#Where is the plugin-registry.xml?] [How do I know which phase a plug-in is associated with?](#How do I know which phase a plug-in is associated with?]</p></section><section> @@ -210,11 +210,11 @@ under the License. [What is the purpose of remote repository (other than ibiblio)?](#What is the purpose of remote repository (other than ibiblio)?]</p></section><section> <h3><a name="Errors"></a>Errors</h3> <p>[#Why do I get java.lang.NoClassDefFoundError: org/codehaus/classworlds/Launcher when I try to execute Maven?] -[What does the “ERROR Cannot override read-only parameter < parameter_name>” message, when running mean?](#What does the “ERROR Cannot override read-only parameter < parameter_name>” message, when running mean?] -[What does the FATAL ERROR with the message *‘Class org.apache.commons.logging.impl.Jdk14Logger does not implement Log’* when using the maven-checkstyle-plugin mean?](#What does the FATAL ERROR with the message <i>‘Class org.apache.commons.logging.impl.Jdk14Logger does not implement Log’</i> when using the maven-checkstyle-plugin mean?] +[What does the ERROR Cannot override read-only parameter < parameter_name> message, when running mean?](#What does the ERROR Cannot override read-only parameter < parameter_name> message, when running mean?] +[What does the FATAL ERROR with the message *Class org.apache.commons.logging.impl.Jdk14Logger does not implement Log* when using the maven-checkstyle-plugin mean?](#What does the FATAL ERROR with the message <em>Class org.apache.commons.logging.impl.Jdk14Logger does not implement Log</em> when using the maven-checkstyle-plugin mean?] [Unsupported Protocol Error when deploying a 3rd party jar. What should I do?](#Unsupported Protocol Error when deploying a 3rd party jar. What should I do?] -[I have my web.xml in my customed directory layout for my webapp, but why am I getting the error “Deployment descriptor < Path >\WEB-INF\web.xml does not exist”?](#I have my web.xml in my customed directory layout for my webapp, but why am I getting the error “Deployment descriptor < Path >\WEB-INF\web.xml does not exist”?] -[How can I stop this “WARNING While downloading artifactId-artifactId-version This artifact has been relocated to groupId-artifactId-version”?](#How can I stop this “WARNING While downloading artifactId-artifactId-version This artifact has been relocated to groupId-artifactId-version”?]</p></section><section> +[I have my web.xml in my customed directory layout for my webapp, but why am I getting the error Deployment descriptor < Path >\WEB-INF\web.xml does not exist?](#I have my web.xml in my customed directory layout for my webapp, but why am I getting the error Deployment descriptor < Path >\WEB-INF\web.xml does not exist?] +[How can I stop this WARNING While downloading artifactId-artifactId-version This artifact has been relocated to groupId-artifactId-version?](#How can I stop this WARNING While downloading artifactId-artifactId-version This artifact has been relocated to groupId-artifactId-version?]</p></section><section> <h3><a name="Maven_Comparisons"></a>Maven Comparisons</h3> <p>[What is the difference between Maven and Ivy?](#What is the difference between Maven and Ivy?]</p></section><section> <h3><a name="Ant"></a>Ant</h3> @@ -234,11 +234,11 @@ under the License. <h3><a name="Deploy"></a>Deploy</h3> <p>[How do I deploy my binary during the deploy phase?](#How do I deploy my binary during the deploy phase?] [Is there a way to use the deploy phase to perform some tasks without maven trying to install the artifact to a maven repository?](#Is there a way to use the deploy phase to perform some tasks without maven trying to install the artifact to a maven repository?] -[Is maven ‘deploy’ goal and actually copying of a dependency or artifact jar to remote repository same?](#Is maven ‘deploy’ goal and actually copying of a dependency or artifact jar to remote repository same?]</p></section><section> +[Is maven deploy goal and actually copying of a dependency or artifact jar to remote repository same?](#Is maven deploy goal and actually copying of a dependency or artifact jar to remote repository same?]</p></section><section> <h3><a name="Release"></a>Release</h3> -<p>[#When I run mvn release:prepare, I get a build failure saying “Unable to tag SCM, File (…) already exists”. However, the tag does not exist. What is wrong?]</p></section><section> +<p>[#When I run mvn release:prepare, I get a build failure saying Unable to tag SCM, File () already exists. However, the tag does not exist. What is wrong?]</p></section><section> <h3><a name="Profiles"></a>Profiles</h3> -<p>[Can a profile inherit the configuration of a “sibling” profile?](#Can a profile inherit the configuration of a “sibling” profile?]</p></section><section> +<p>[Can a profile inherit the configuration of a sibling profile?](#Can a profile inherit the configuration of a sibling profile?]</p></section><section> <h3><a name="Testing"></a>Testing</h3> <p>[How do I prevent tests from running twice, after adding a configuration for the surefire plugin?](#How do I prevent tests from running twice, after adding a configuration for the surefire plugin?] [How do I skip unit tests when building a project?](#How do I skip unit tests when building a project?] @@ -253,15 +253,15 @@ under the License. [Is it possible to exclude a package from the generated jar file?](#Is it possible to exclude a package from the generated jar file?] [How not to include all jar files from parent pom?](#How not to include all jar files from parent pom?] [How do I filter resources in the war?](#How do I filter resources in the war?] -[How do I prevent including JARs in WEB-INF/lib? I need a “compile only” scope!](#How do I prevent including JARs in WEB-INF/lib? I need a “compile only” scope!]</p></section><section> +[How do I prevent including JARs in WEB-INF/lib? I need a compile only scope!](#How do I prevent including JARs in WEB-INF/lib? I need a compile only scope!]</p></section><section> <h3><a name="Changing_Locations"></a>Changing Locations</h3> -<p>[How can I change the default location of the generated jar when I command “mvn package”?](#How can I change the default location of the generated jar when I command “mvn package”?] +<p>[How can I change the default location of the generated jar when I command mvn package?](#How can I change the default location of the generated jar when I command mvn package?] [Is there a way to specify a different output directory without having to edit the pom or configuration file each time I do a build?](#Is there a way to specify a different output directory without having to edit the pom or configuration file each time I do a build?] [How do I set the base directory for creating the packages created by assembly?](#How do I set the base directory for creating the packages created by assembly?] [Is it possible to create my own directory structure?](#Is it possible to create my own directory structure?]</p></section><section> <h3><a name="JDK"></a>JDK</h3> -<p>[#I would like clarification on what version of the JDK is required for m2 – particularly with respect to creating Plugins.] -[#i'm wondering what a “snapshot” actually is.] +<p>[#I would like clarification on what version of the JDK is required for m2 particularly with respect to creating Plugins.] +[#i'm wondering what a snapshot actually is.] [How do I configure a project to use a specific version of a JDK?](#How do I configure a project to use a specific version of a JDK?]</p></section><section> <h3><a name="Other"></a>Other</h3> <p>[Maven doesn't work, how do I get help?](#Maven doesn't work, how do I get help?] @@ -279,7 +279,7 @@ under the License. [Where to get sun.jdk-tools-jar-1.4.0 on MacOSX?](#Where to get sun.jdk-tools-jar-1.4.0 on MacOSX?] [How can I make the war plugin produces an exploded war instead of .war file?](#How can I make the war plugin produces an exploded war instead of .war file?] [Is there any variable to determine what version of an artifact was deployed after the deploy step runs?](#Is there any variable to determine what version of an artifact was deployed after the deploy step runs?] -[How do I get the top line of a table to be “headers” for that column in APT?](#How do I get the top line of a table to be “headers” for that column in APT?] +[How do I get the top line of a table to be headers for that column in APT?](#How do I get the top line of a table to be headers for that column in APT?] [What is the suggested way to download a remote file?](#What is the suggested way to download a remote file?] [How do I install the package generated by the assembly plugin to be installed in the local repository?](#How do I install the package generated by the assembly plugin to be installed in the local repository?] [Is it possible to use HashMap as configurable parameter in a plugin? How do I configure that in pom.xml?](#Is it possible to use HashMap as configurable parameter in a plugin? How do I configure that in pom.xml?] @@ -290,7 +290,7 @@ under the License. [What does (f) and (s) debug output mean?](#What does (f) and (s) debug output mean?] [How to resolve problems with jtaxxx.jar?](#How to resolve problems with jtaxxx.jar?] [How to make Continuum work in service mode when an Error 1067 is reported?](#How to make Continuum work in service mode when an Error 1067 is reported?] -[Using xdoclet, how come “” does not work?](#Using xdoclet, how come “” does not work?] +[Using xdoclet, how come does not work?](#Using xdoclet, how come does not work?] [I don't have a domain name and I don't want use my employer's domain name. What should I name my plugin package?](#I don't have a domain name and I don't want use my employer's domain name. What should I name my plugin package?] [pom.xml or settings.xml? What is the best practice configuration usage for these files?](#pom.xml or settings.xml? What is the best practice configuration usage for these files?] [What is reactorProjects? executedProject?](#What is reactorProjects? executedProject?] @@ -299,8 +299,8 @@ under the License. [Does maven support automated build and test from non-Java applications?](#Does maven support automated build and test from non-Java applications?] [What would be the appropriate way to enable inheritance of classes in the test hierarchy across modules during the test-compile phase of a multi-pom project?](#What would be the appropriate way to enable inheritance of classes in the test hierarchy across modules during the test-compile phase of a multi-pom project?] [Is Julia Antonova/Tumlare out of the office?](#Is Julia Antonova/Tumlare out of the office?] -[How to encrypt a secure password that includes an Ampersand](#How to encrypt a secure password that includes an Ampersand]</p> -<h1>Answered Questions</h1></section><section> +[How to encrypt a secure password that includes an Ampersand](#How to encrypt a secure password that includes an Ampersand]</p></section></section></section><section> +<h1><a name="Answered_Questions"></a>Answered Questions</h1><section><section> <h3><a name="How_do_I_merge_a_list_of_configuration_items_in_a_parent_POM_with_those_in_a_child_POM.3F"></a>How do I merge a list of configuration items in a parent POM with those in a child POM?</h3> <p>Since plugin configurations are handled as XML DOM instances by the core, there is an ever-present struggle between when to merge child elements' values with one another (when the child's <code><source></code> overrides the parent's, for example), and when you want to append new child elements to the existing list (as in the example above, or any time you have a list of items to aggregate during inheritance).</p> <p>We've solved this problem using an attribute, <code>combine.children</code>. You simply specify this attribute, with the value of <code>append</code> at the parent element where such aggregation should occur, and Maven will switch its merge behavior for that element's children.</p> @@ -335,7 +335,7 @@ under the License. </code></pre></div> <p>(If you're using an earlier version of Maven than trunk (revId 545315), the order above will be three, one, two.)</p></section><section> <h3><a name="Why_do_I_not_get_an_index.html_page_generated_for_my_project_website.3F"></a>Why do I not get an index.html page generated for my project website?</h3> -<p>The usual cause of this is configuring maven-project-info-reports plugin and leaving out the ‘index’ report.</p> +<p>The usual cause of this is configuring maven-project-info-reports plugin and leaving out the index report.</p> <div class="source"><pre class="prettyprint linenums"><code> <plugin> <groupId>org.apache.maven.plugins</groupId> @@ -353,16 +353,16 @@ under the License. </reportSets> </plugin> </code></pre></div></section><section> -<h3><a name="How_do_I_resolve_the_.E2.80.9C.3C_plugin_name_.3E_does_not_exist_or_no_valid_version.E2.80.9D_error.3F"></a>How do I resolve the “< plugin name > does not exist or no valid version” error?</h3> +<h3><a name="How_do_I_resolve_the_null.3C_plugin_name_.3E_does_not_exist_or_no_valid_versionnull_error.3F"></a>How do I resolve the < plugin name > does not exist or no valid version error?</h3> <p>This error indicates that Maven is either unable to access the required plug-in from your local repository, or unable to access the official or <code>central</code> Maven plug-in repository.</p> <p>To resolve this error:</p> <ul> -<li>If you are behind a http proxy, please check the Maven2 <a class="externalLink" href="http://maven.apache.org/guides/mini/guide-proxies.html">proxy settings guide</a>.</li> +<li>If you are behind a http proxy, please check the Maven2 <a href="http://maven.apache.org/guides/mini/guide-proxies.html" class="externalLink">proxy settings guide</a>.</li> <li>If you are upgrading Maven from an older version, try running with -U. This will force an update check on all plug-ins.</li> </ul> -<p>If the error persists, browse <a class="externalLink" href="http://www.mail-archive.com/users@maven.apache.org/">archived discussions</a>, post to the Maven user list, or log a <a class="externalLink" href="http://jira.codehaus.org/browse/MNG">ticket</a> describing your problem, if you think it is a bug. Tickets may also be issued for feature enhancement requests, and other tasks.</p> -<p><i>Errors, Dependencies, Plugins</i></p></section><section> +<p>If the error persists, browse <a href="http://www.mail-archive.com/users@maven.apache.org/" class="externalLink">archived discussions</a>, post to the Maven user list, or log a <a href="http://jira.codehaus.org/browse/MNG" class="externalLink">ticket</a> describing your problem, if you think it is a bug. Tickets may also be issued for feature enhancement requests, and other tasks.</p> +<p><em>Errors, Dependencies, Plugins</em></p></section><section> <h3><a name="How_do_I_install_a_file_in_my_local_repository_along_with_a_generic_POM.3F"></a>How do I install a file in my local repository along with a generic POM?</h3> <p>You may do this by typing this command (please take note that this is a single line only).</p> @@ -375,8 +375,8 @@ under the License. -DgeneratePom=true </code></pre></div> <p>This command installs the jar in your local repository with the generated generic pom. -{{Well, this doesn't work in Maven 2.0.2. It just gives the message “Cannot execute mojo: install-file. It requires a project with an existing pom.xml, but the build is not using one.” -<a class="externalLink" href="mailto:-krei...@imcode.com">-krei...@imcode.com</a>}}</p> -<p><i>Repositories</i></p></section><section> +{{Well, this doesn't work in Maven 2.0.2. It just gives the message Cannot execute mojo: install-file. It requires a project with an existing pom.xml, but the build is not using one. -<a href="mailto:-krei...@imcode.com" class="externalLink">-krei...@imcode.com</a>}}</p> +<p><em>Repositories</em></p></section><section> <h3><a name="How_do_I_install_a_file_in_my_local_repository_along_with_my_customized_POM.3F"></a>How do I install a file in my local repository along with my customized POM?</h3> <p>The solution requires the <code>-DpomFile=<path-to-pom></code> parameter just like the sample below.</p> @@ -389,15 +389,15 @@ under the License. -DpomFile=<path-to-pom> </code></pre></div> <p>This command will install the file in your local repository along with your customed pom. -<i>Repositories</i></p></section><section> +<em>Repositories</em></p></section><section> <h3><a name="How_do_I_include.2Fexclude_the_other_modules_in_the_navigation_menu_in_the_parent_site.3F"></a>How do I include/exclude the other modules in the navigation menu in the parent site?</h3> -<p><a class="externalLink" href="http://jira.codehaus.org/browse/MNG-661">MNG-661</a>, provides a simple patch which provides parent and module links using the project URLs which as you +<p><a href="http://jira.codehaus.org/browse/MNG-661" class="externalLink">MNG-661</a>, provides a simple patch which provides parent and module links using the project URLs which as you correctly point out only work when the site is deployed.</p> -<p><i>Plugins & Lifecycle</i></p> -<p><i>General</i></p></section><section> +<p><em>Plugins & Lifecycle</em></p> +<p><em>General</em></p></section><section> <h3><a name="What_is_the_difference_between_Maven_and_Ivy.3F"></a>What is the difference between Maven and Ivy?</h3> -<p>For a comparison of Maven's features vs Ivy's you can refer to our <a class="externalLink" href="http://docs.codehaus.org/display/MAVEN/Feature+Comparisons">feature comparison</a></p> -<p><i>General</i></p></section><section> +<p>For a comparison of Maven's features vs Ivy's you can refer to our <a href="http://docs.codehaus.org/display/MAVEN/Feature+Comparisons" class="externalLink">feature comparison</a></p> +<p><em>General</em></p></section><section> <h3><a name="How_do_I_get_a_plug-in.27s_dependencies_from_a_Mojo.3F"></a>How do I get a plug-in's dependencies from a Mojo?</h3> <div class="source"><pre class="prettyprint linenums"><code>public class MyMojo @@ -448,13 +448,13 @@ correctly point out only work when the s <h3><a name="Does_the_v4.0.0_POM_include_a_.3C_versions.2F_.3E_element.3F"></a>Does the v4.0.0 POM include a < versions/ > element?</h3> <p>The POM does not inlcude a <code><versions/></code> element. The POM reflects the current state of a project's build only, not a historical build log. The POM is not designed to track historical information, as it would be difficult for developers to always add this information manually, i.e., to always remember to add it or to ensure that the correct information is added when multiple branches are involved.</p> <p>However, if the SCM tag of the <code><scm></code> section of the POM is populated, the repository records build versions, enabling developers to reconstruct the information for each released build.</p> -<p><i>POM, General</i></p></section><section> +<p><em>POM, General</em></p></section><section> <h3><a name="How_do_I_create_a_report_that_does_not_require_Doxia.27s_Sink_interface.3F"></a>How do I create a report that does not require Doxia's Sink interface?</h3> <p>Make it a report and override the <code>isExternalReport()</code> method to return true.</p> -<p><i>Sites & Reporting</i></p></section><section> +<p><em>Sites & Reporting</em></p></section><section> <h3><a name="How_do_I_prevent_verification_warnings_with_custom_repositories.3F"></a>How do I prevent verification warnings with custom repositories?</h3> <p>Warnings from custom repositories (usually located within the organization's network, or even on the same workstation) are triggered when Maven tries to verify the integrity of the files in the repository. This verification is done via the SHA1 or MD5 sum of the file. If these sum files do not exist, then a warning appears.</p> -<p>Support for downloading the security sum files is not yet included in the Maven2 distribution. There are free command-line utilities on the Internet that generate these sums. Below is an example of a bash script (use <a class="externalLink" href="http://cygwin.com">Cygwin</a> if you are using a windows machine) that generates sha1sum for all jar, xml and pom files contained in the directory where it is executed:</p> +<p>Support for downloading the security sum files is not yet included in the Maven2 distribution. There are free command-line utilities on the Internet that generate these sums. Below is an example of a bash script (use <a href="http://cygwin.com" class="externalLink">Cygwin</a> if you are using a windows machine) that generates sha1sum for all jar, xml and pom files contained in the directory where it is executed:</p> <div class="source"><pre class="prettyprint linenums"><code>#!/usr/bin/bash @@ -493,15 +493,15 @@ processFile "$tmpFile" rm "$tmpFile" </code></pre></div> -<p>The script above has been tested on <a class="externalLink" href="http://cygwin.com">Cygwin</a> and is provided “as-is” and with no guarantee. -<i>Errors, Repositories</i></p></section><section> +<p>The script above has been tested on <a href="http://cygwin.com" class="externalLink">Cygwin</a> and is provided as-is and with no guarantee. +<em>Errors, Repositories</em></p></section><section> <h3><a name="What_does_the_.22ERROR:_Cannot_override_read-only_parameter:_.3Cparameter_name.3E_.22_message.2C_when_running_.3Cplugin_name.3E:_mean.3F"></a>What does the "ERROR: Cannot override read-only parameter: <code><parameter_name></code> " message, when running <plugin_name>: mean?</h3> <p>This means that the parameter being overriden in the pom.xml is read-only. Hence, it is not possible to override this parameter.</p> -<p><i>Errors, POM</i></p></section><section> +<p><em>Errors, POM</em></p></section><section> <h3><a name="How_do_I_generate_Maven_plug-in_sites.2C_with_pages_that_include_an_overview_of_the_goals_and_parameters_for_each_plug-in.3F"></a>How do I generate Maven plug-in sites, with pages that include an overview of the goals and parameters for each plug-in?</h3> <p>Include maven-plugin-plugin as a report.</p> -<p><i>Plugin Requests, Sites & Reporting</i></p></section><section> -<h3><a name="Can_I_define_the_antrun_plugin_to_be_executed_on_demand_like_.E2.80.9Cmvn_antrun:run.E2.80.9D.3F"></a>Can I define the antrun plugin to be executed on demand like “mvn antrun:run”?</h3> +<p><em>Plugin Requests, Sites & Reporting</em></p></section><section> +<h3><a name="Can_I_define_the_antrun_plugin_to_be_executed_on_demand_like_nullmvn_antrun:runnull.3F"></a>Can I define the antrun plugin to be executed on demand like mvn antrun:run?</h3> <p>The antrun plugin can be executed on demand only if:</p> <ul> @@ -511,17 +511,17 @@ rm "$tmpFile" </ul> <p>However, it is recommended that developers write plugins for their goals (Ant support for plugins will be available soon, currently you must write them in java or beanshell).</p> -<p><i>Plugins and Lifecycle, Ant-related</i></p></section><section> +<p><em>Plugins and Lifecycle, Ant-related</em></p></section><section> <h3><a name="How_do_I_properly_populate_variables.2C_when_extending_a_mojo_from_another_plugin.3F"></a>How do I properly populate variables, when extending a mojo from another plugin?</h3> <p>When creating plugins, the field metadata is read from source files, so it is not available when the original source is not available. While the metadata is available in the plugin in <code>META-INF/maven/plugin.xml</code>, currently, there is no way to incorporate it when building a new plugin.</p> <p>It is currently recommended that plug-ins be built using composition, instead of inheritence.</p> -<p><i>Plugin Requests, Design, Patterns & Best Practices</i></p></section><section> +<p><em>Plugin Requests, Design, Patterns & Best Practices</em></p></section><section> <h3><a name="How_do_I_access_artifacts_if_Ibiblio_is_down.3F"></a>How do I access artifacts if Ibiblio is down?</h3> <p>To access artifacts if Ibiblio is down, use any of its mirror sites.</p> -<p><a class="externalLink" href="http://maven.apache.org/guides/mini/guide-mirror-settings.html">Guide mirror settings</a></p> -<p><i>Repositories, General</i></p></section><section> +<p><a href="http://maven.apache.org/guides/mini/guide-mirror-settings.html" class="externalLink">Guide mirror settings</a></p> +<p><em>Repositories, General</em></p></section><section> <h3><a name="How_do_I_get_a_list_of_archetypes.3F"></a>How do I get a list of archetypes?</h3> -<p>To get a list of archetypes, refer to the following page [<a class="externalLink" href="http://svn.apache.org/viewcvs.cgi/maven/archetype/trunk/maven-archetypes">http://svn.apache.org/viewcvs.cgi/maven/archetype/trunk/maven-archetypes</a>)</p></section><section> +<p>To get a list of archetypes, refer to the following page [<a href="http://svn.apache.org/viewcvs.cgi/maven/archetype/trunk/maven-archetypes" class="externalLink">http://svn.apache.org/viewcvs.cgi/maven/archetype/trunk/maven-archetypes</a>)</p></section><section> <h3><a name="How_do_I_specify_my_remote_repo_in_Maven.3F"></a>How do I specify my remote repo in Maven?</h3> <p>To specify a remote repo in Maven, add the <code><repositories></code> element to the POM:</p> @@ -533,8 +533,8 @@ plugins will be available soon, currentl </repository> </repositories> </code></pre></div> -<p>Or, refer to the following page [<a class="externalLink" href="http://maven.apache.org/guides/mini/guide-multiple-repositories.html">http://maven.apache.org/guides/mini/guide-multiple-repositories.html</a>) -<i>Repositories</i></p></section><section> +<p>Or, refer to the following page [<a href="http://maven.apache.org/guides/mini/guide-multiple-repositories.html" class="externalLink">http://maven.apache.org/guides/mini/guide-multiple-repositories.html</a>) +<em>Repositories</em></p></section><section> <h3><a name="How_do_I_specify_which_output_folders_the_Eclipse_plugin_puts_into_the_.classpath_file.3F"></a>How do I specify which output folders the Eclipse plugin puts into the .classpath file?</h3> <div class="source"><pre class="prettyprint linenums"><code><build> @@ -553,11 +553,11 @@ plugins will be available soon, currentl ... </build> </code></pre></div> -<p><i>Plugins and Lifecycle, IDEs</i></p> -<p><i>General, Plugins and Lifecycle</i></p></section><section> -<h3><a name="Can_a_profile_inherit_the_configuration_of_a_.E2.80.9Csibling.E2.80.9D_profile.3F"></a>Can a profile inherit the configuration of a “sibling” profile?</h3> +<p><em>Plugins and Lifecycle, IDEs</em></p> +<p><em>General, Plugins and Lifecycle</em></p></section><section> +<h3><a name="Can_a_profile_inherit_the_configuration_of_a_nullsiblingnull_profile.3F"></a>Can a profile inherit the configuration of a sibling profile?</h3> <p>No. Profiles merge when their ID's match - so you can inherit them from a parent POM (but you can't inherit profiles from the same POM).</p> -<p><i>Inheritence and Interpolation, Plugins and Lifecycle, POM</i></p></section><section> +<p><em>Inheritence and Interpolation, Plugins and Lifecycle, POM</em></p></section><section> <h3><a name="How_do_I_run_an_ant_task_twice.2C_against_two_different_phases.3F"></a>How do I run an ant task twice, against two different phases?</h3> <p>You can specify multiple execution elements under the executions tag, giving each a different id and binding them at different phases.</p> @@ -592,7 +592,7 @@ plugins will be available soon, currentl </executions> </plugin> </code></pre></div> -<p><i>Ant-related</i></p></section><section> +<p><em>Ant-related</em></p></section><section> <h3><a name="How_do_I_prevent_tests_from_running_twice.2C_after_adding_a_configuration_for_the_surefire_plugin.3F"></a>How do I prevent tests from running twice, after adding a configuration for the surefire plugin?</h3> <p>Declare the configuration outside of the executions tag of the plugin.</p> @@ -610,7 +610,7 @@ plugins will be available soon, currentl </configuration> </plugin> </code></pre></div> -<p><i>Plugins and Lifecycle, Sites & Reporting</i></p></section><section> +<p><em>Plugins and Lifecycle, Sites & Reporting</em></p></section><section> <h3><a name="How_do_I_integrate_static_.28x.29html_into_my_Maven_site.3F"></a>How do I integrate static (x)html into my Maven site?</h3> <p>You can integrate your static pages in this several steps,</p> <ul> @@ -652,15 +652,15 @@ plugins will be available soon, currentl <item name="<put-name-here>" xhref="<filename-of-the-static-page>"/> </menu> </code></pre></div> -<p> <i>Sites & Reporting</i></p></section><section> +<p> <em>Sites & Reporting</em></p></section><section> <h3><a name="How_do_I_specify_that_all_web_modules_will_inherit_the_group.27s_common_files_from_a_parent_web_module.3F"></a>How do I specify that all web modules will inherit the group's common files from a parent web module?</h3> <p>maven-war-plugin 2.0-beta-3 and later supports merging of wars. Just reference the common WAR project from another WAR project as a dependency of <code><type>war</type></code> and it will automatically be merged.</p> -<p>See [<a class="externalLink" href="http://jira.codehaus.org/browse/MWAR-8">http://jira.codehaus.org/browse/MWAR-8</a>)</p> -<p><i>Inheritence and Interpolation</i></p></section><section> +<p>See [<a href="http://jira.codehaus.org/browse/MWAR-8" class="externalLink">http://jira.codehaus.org/browse/MWAR-8</a>)</p> +<p><em>Inheritence and Interpolation</em></p></section><section> <h3><a name="How_do_I_determine_which_POM_contains_missing_transitive_dependency.3F"></a>How do I determine which POM contains missing transitive dependency?</h3> <p>run <code>mvn -X</code></p> -<p><i>POM, Dependencies</i></p> -<p><i>General, POM, Plugins and Lifecycle, Command Line</i></p></section><section> +<p><em>POM, Dependencies</em></p> +<p><em>General, POM, Plugins and Lifecycle, Command Line</em></p></section><section> <h3><a name="How_do_I_determine_the_stale_resources_in_a_Mojo_to_avoid_reprocessing_them.3F"></a>How do I determine the stale resources in a Mojo to avoid reprocessing them?</h3> <p>This can be done using the following piece of code:</p> @@ -685,9 +685,9 @@ In order to use this API you must includ </dependency> </dependencies> </code></pre></div> -<p><i>POM, Plugin API</i></p></section><section> -<h3><a name="What_does_the_FATAL_ERROR_with_the_message_.E2.80.9CClass_org.apache.commons.logging.impl.Jdk14Logger_does_not_implement_Log.E2.80.9D_when_using_the_maven-checkstyle-plugin_mean.3F"></a>What does the FATAL ERROR with the message <i>“Class org.apache.commons.logging.impl.Jdk14Logger does not implement Log”</i> when using the maven-checkstyle-plugin mean?</h3> -<p>Checkstyle uses commons-logging, which has classloader problems when initialized within a Maven plugin's container. This results in the above message - if you run with ‘-e’, you'll see something like the following:</p><hr /></section></section><section> +<p><em>POM, Plugin API</em></p></section><section> +<h3><a name="What_does_the_FATAL_ERROR_with_the_message_nullClass_org.apache.commons.logging.impl.Jdk14Logger_does_not_implement_Lognull_when_using_the_maven-checkstyle-plugin_mean.3F"></a>What does the FATAL ERROR with the message <em>Class org.apache.commons.logging.impl.Jdk14Logger does not implement Log</em> when using the maven-checkstyle-plugin mean?</h3> +<p>Checkstyle uses commons-logging, which has classloader problems when initialized within a Maven plugin's container. This results in the above message - if you run with -e, you'll see something like the following:</p><hr /></section></section><section> <h2><a name="Caused_by:_org.apache.commons.logging.LogConfigurationException:_org.apache.commons.logging.LogConfigurationException:_Class_org.apache.commons.logging.impl.Jdk14Logger_does_not_implement_Log"></a>Caused by: org.apache.commons.logging.LogConfigurationException: org.apache.commons.logging.LogConfigurationException: Class org.apache.commons.logging.impl.Jdk14Logger does not implement Log</h2> <p>buried deep in the stacktrace.</p> <p>The only workaround we currently have for this problem is to include another commons-logging Log implementation in the plugin itself. So, you can solve the problem by adding the following to your plugin declaration in your POM:</p> @@ -721,13 +721,13 @@ In order to use this API you must includ </code></pre></div> <p>While this may seem a counter-intuitive way of configuring a report, it's important to remember that Maven plugins can have a mix of reports and normal mojos. When a POM has to configure extra dependencies for a plugin, it should do so in the normal plugins section. We will probably try to fix this problem before the next release of the checkstyle plugin.</p> -<p><i>UPDATE:</i> This problem has been fixed in the SVN trunk version of the checkstyle plugin, which should be released very soon. -<i>Plugins and Lifecycle, Sites & Reporting, Errors</i></p><section> +<p><em>UPDATE:</em> This problem has been fixed in the SVN trunk version of the checkstyle plugin, which should be released very soon. +<em>Plugins and Lifecycle, Sites & Reporting, Errors</em></p><section> <h3><a name="Where_do_I_configure_report_plug-ins.2C_like_javadoc.3F"></a>Where do I configure report plug-ins, like javadoc?</h3> <p>Generally, you should configure reporting in the <code><reporting></code> (vs. <code><build></code>) section of the POM. Configuration there applies to both the site, and when run on the command line, and adding the plugin there adds the report to the generated site.</p> <p>Configuration in the build section is only used during the normal lifecycle or the command line invocation (eg <code>javadoc:javadoc</code>).</p> <p>Configuration should go there if you do not want the report on the site, or the configuration differs from what is on the site (eg, some plugins have a fail build option).</p> -<p><i>Sites & Reporting, Plugins and Lifecycle, Command Line</i></p></section><section> +<p><em>Sites & Reporting, Plugins and Lifecycle, Command Line</em></p></section><section> <h3><a name="How_do_I_deploy_my_binary_during_the_deploy_phase.3F"></a>How do I deploy my binary during the deploy phase?</h3> <div class="source"><pre class="prettyprint linenums"><code><plugin> @@ -747,7 +747,7 @@ We will probably try to fix this problem </plugin> </code></pre></div> <p>Then run <code>mvn deploy</code>. -<i>Deployment</i></p></section><section> +<em>Deployment</em></p></section><section> <h3><a name="How_do_I_add_main_class_in_a_generated_jar.27s_manifest.3F"></a>How do I add main class in a generated jar's manifest?</h3> <p>Configure the maven-jar-plugin and add your main class.</p> @@ -775,10 +775,10 @@ We will probably try to fix this problem -DrepositoryId=<id-to-map-on-server> -Durl=<url-of-remote-repo> </code></pre></div> -<p><i>Repositories, Command Line</i></p></section><section> +<p><em>Repositories, Command Line</em></p></section><section> <h3><a name="Does_a_POM_inherit_its_resources.3F"></a>Does a POM inherit its resources?</h3> <p>Yes, resources are inherited, but only if the child pom does not define any resources. If it does, then the project just uses those resources defined in its pom and the parents resources are overridden.</p> -<p><i>POM, Inheritence and Interpolation</i></p></section><section> +<p><em>POM, Inheritence and Interpolation</em></p></section><section> <h3><a name="How_do_I_use_SNAPSHOT_versions_of_plug-ins.3F"></a>How do I use SNAPSHOT versions of plug-ins?</h3> <p>[http://maven.apache.org/guides/development/guide-testing-development-plugins.html]</p></section><section> <h3><a name="How_do_I_run_a_build.2Fpackage.2Fdeploy_process_without_waiting_for_reports_or_unit_tests.2C_in_order_to_quickly_deploy_to_an_integration_box.3F"></a>How do I run a build/package/deploy process without waiting for reports or unit tests, in order to quickly deploy to an integration box?</h3> @@ -834,20 +834,20 @@ We will probably try to fix this problem <li>CLI parameters</li> </ul> <p>where the last overrides the previous.</p> -<p><i>General, Inheritence and Interpolation, Design, Patterns & Best Practices</i></p></section><section> +<p><em>General, Inheritence and Interpolation, Design, Patterns & Best Practices</em></p></section><section> <h3><a name="How_do_I_add_my_generated_sources_to_the_compile_path_of_Maven.2C_when_using_modello.3F"></a>How do I add my generated sources to the compile path of Maven, when using modello?</h3> <p>Modello generate the sources in the generate-sources phase and automatically adds the source directory for compilation in maven. So you don't have to copy the generated sources.</p> <p>You have to declare the modello-plugin in the build of your plugin for source generation (in that way the sources are generated each time).</p> -<p><i>Plugins and Lifecycle</i></p></section><section> +<p><em>Plugins and Lifecycle</em></p></section><section> <h3><a name="Can_I_add_a_java_source_to_my_war_package.3F"></a>Can I add a java source to my war package?</h3> <p>You can't, but you can use the assembly plugin to create a source distribution and a binary distribution for your project</p> <p>Please refer to these sites for more info [http://maven.apache.org/guides/mini/guide-assemblies.html] [http://maven.apache.org/plugins/maven-assembly-plugin/howto.html]</p> -<p><i>Deployments, Plugins and Lifecycle</i></p></section><section> -<h3><a name="What_does_the_.E2.80.9CYou_cannot_have_two_plugin_executions_with_the_same_.28or_missing.29_.3Cid.2F.3E_elements.E2.80.9D_message_mean.3F"></a>What does the “You cannot have two plugin executions with the same (or missing) <code><id/></code> elements” message mean?</h3> +<p><em>Deployments, Plugins and Lifecycle</em></p></section><section> +<h3><a name="What_does_the_nullYou_cannot_have_two_plugin_executions_with_the_same_.28or_missing.29_.3Cid.2F.3E_elementsnull_message_mean.3F"></a>What does the You cannot have two plugin executions with the same (or missing) <code><id/></code> elements message mean?</h3> <p>It means that you have executed a plugin multiple times with the same <code><id></code>. Provide each <code><execution></code> with a unique <code><id></code> then it would be ok.</p> -<p><i>Errors, Plugins and Lifecycle</i></p></section><section> +<p><em>Errors, Plugins and Lifecycle</em></p></section><section> <h3><a name="Can_I_disable_transitive_dependencies.3F"></a>Can I disable transitive dependencies?</h3> <p>No you can't, but you may exclude the dependencies you dont want to include in your project.</p> <p>Following is a sample on how to exclude transitive dependencies.</p> @@ -868,14 +868,14 @@ We will probably try to fix this problem </dependency> </project> </code></pre></div> -<p><i>Dependencies, Design, Patterns & Best Practices</i></p></section><section> +<p><em>Dependencies, Design, Patterns & Best Practices</em></p></section><section> <h3><a name="Where_can_I_get_offline_documentation_for_Maven.3F"></a>Where can I get offline documentation for Maven?</h3> <p>Check it out from [http://svn.apache.org/repos/asf/maven/site/trunk] and run mvn site:site</p> -<p><i>General, Sites & Reporting</i></p></section><section> +<p><em>General, Sites & Reporting</em></p></section><section> <h3><a name="How_do_I_skip_unit_tests_when_building_a_project.3F"></a>How do I skip unit tests when building a project?</h3> <p>Run the mvn command with <code>-Dmaven.test.skip=true</code> argument.</p> <p>Also see [How do I run a build/package/deploy process without waiting for reports or unit tests, so that I can quickly deploy to an integration box?]</p> -<p><i>Sites & Reporting, General</i></p></section><section> +<p><em>Sites & Reporting, General</em></p></section><section> <h3><a name="How_do_I_create_a_command_line_parameter_.28i.e..2C_-Dname.3Dvalue_.29_in_my_mojo.3F"></a>How do I create a command line parameter (i.e., -Dname=value ) in my mojo?</h3> <p>In your mojo, put <code>expression=$\{<exp>\}</code> in your parameter field</p> @@ -886,7 +886,7 @@ private String exp; </code></pre></div> <p>You may now able to pass parameter values to the command line. <code>mvn \-Dexpression.name=value install</code></p> -<p><i>Command Line</i></p></section><section> +<p><em>Command Line</em></p></section><section> <h3><a name="What_is_the_purpose_of_displaying_read-only.2C_plug-in_fields_in_user_documentation.2C_if_they_are_not_configurable_in_the_project_descriptor.3F"></a>What is the purpose of displaying read-only, plug-in fields in user documentation, if they are not configurable in the project descriptor?</h3> <p>Often, parameters are specified as read-only to indicate that its value should be changed indirectly, rather than in the plugins <code><configuration/></code> section. For instance, I may have a plugin that declares a parameter as such:</p> @@ -897,22 +897,22 @@ private String exp; */ private File buildDir; </code></pre></div> -<p>In this case, my plugin wants to output something to the project's build directory. If this were configured directly on the plugin, it might not be cleaned up when the user issued <i>‘mvn clean’</i>, so instead I mark it as <code>@readonly</code>. This tells the user that she should modify the structure referenced by <i>default-value</i>(i.e. <code><project><build><directory/></code> in the POM) instead, which will allow this plugin to be a good citizen in the build process.</p></section><section> +<p>In this case, my plugin wants to output something to the project's build directory. If this were configured directly on the plugin, it might not be cleaned up when the user issued <em>mvn clean</em>, so instead I mark it as <code>@readonly</code>. This tells the user that she should modify the structure referenced by <em>default-value</em>(i.e. <code><project><build><directory/></code> in the POM) instead, which will allow this plugin to be a good citizen in the build process.</p></section><section> <h3><a name="I.27ve_just_created_a_maven_plugin._Is_there_a_sample_plugin_integration_test_I_can_use.3F"></a>I've just created a maven plugin. Is there a sample plugin integration test I can use?</h3> <p>Each integration test is a separate project. For a plugin, you may want to create a project that will use your plugin and probably put it inside src/test/projects like maven-antrun-plugin, maven-eclipse-plugin, maven-javadoc-plugin and several others. These plugins can be found here: [https://svn.apache.org/repos/asf/maven/plugins/trunk]</p> -<p><i>Plugins and Lifecycle, Sites & Reporting, Integration tests</i></p></section><section> +<p><em>Plugins and Lifecycle, Sites & Reporting, Integration tests</em></p></section><section> <h3><a name="The_snapshot_version_of_the_plugin_is_not_updated_in_the_snapshot_repo.2C_What_should_I_do_to_update_my_copy_of_the_plugin.3F"></a>The snapshot version of the plugin is not updated in the snapshot repo, What should I do to update my copy of the plugin?</h3> <p>If the plugin in the snapshot repo ([http://snapshots.maven.codehaus.org/maven2]) is not yet updated. The only way to update it is to check out the source from SVN and build it.</p></section><section> <h3><a name="Is_there_a_way_to_get_Maven_to_report_the_number_of_compile_errors_found.3F"></a>Is there a way to get Maven to report the number of compile errors found?</h3> -<p>Currently, this type of summary information is not built into the compiler plugin, but it would be possible to add. If this feature is important to you, add your vote to <a class="externalLink" href="http://jira.codehaus.org/browse/MNG-1854">MNG-1854</a>.</p> -<p><i>Sites & Reporting</i></p></section><section> +<p>Currently, this type of summary information is not built into the compiler plugin, but it would be possible to add. If this feature is important to you, add your vote to <a href="http://jira.codehaus.org/browse/MNG-1854" class="externalLink">MNG-1854</a>.</p> +<p><em>Sites & Reporting</em></p></section><section> <h3><a name="In_a_multi-module_project.2C_is_there_any_way_for_Maven_to_build_only_those_modules_that_have_changed_from_the_previous_build_and_leave_the_unchanged_modules_alone_.28i.e._not_build_them.29.3F"></a>In a multi-module project, is there any way for Maven to build only those modules that have changed from the previous build and leave the unchanged modules alone (i.e. not build them)?</h3> <p>Currently, this is not possible. The main reason is that it's non-trivial to determine whether an entire project's build is stale (the project here being one of the modules). It will be dependent on the phase being called, and the packaging of the particular module.</p> -<p><i>Design, Patterns & Best Practices</i></p></section><section> +<p><em>Design, Patterns & Best Practices</em></p></section><section> <h3><a name="Where_can_I_get_the_Maven_plugin_for_Eclipse.3F"></a>Where can I get the Maven plugin for Eclipse?</h3> <p>[http://maven.apache.org/eclipse-plugin.html]</p> <p>There are some flash demos to show the user how to use the plugin.</p> -<p><i>IDEs</i></p></section><section> +<p><em>IDEs</em></p></section><section> <h3><a name="Handle_special_characters_in_site"></a>Handle special characters in site</h3> <p>A solution with eclipse and solaris</p> <p>In eclipse.ini : @@ -934,7 +934,7 @@ Default to ISO-8859-1</p> In <code>$HOME/.profile</code> <code>MAVEN_OPTS="-Xmx512m -Xms512m -Dfile.encoding=ISO-8859-1</code> (mx/ms not mandatory for m2 but for m1). <code>LANG=en_US.ISO8859-15</code> -<i>Sites & Reporting, IDEs</i></p></section><section> +<em>Sites & Reporting, IDEs</em></p></section><section> <h3><a name="How_do_I_generate_sources_with_the_antrun_plug-in.3F"></a>How do I generate sources with the antrun plug-in?</h3> <p>For instance to generate sources add the following to your plugins section NOTE: this may only work in the latest plugin version in SVN</p> @@ -968,10 +968,10 @@ NOTE: this may only work in the latest p </executions> </plugin> </code></pre></div> -<p><i>Ant-related</i> </p></section><section> +<p><em>Ant-related</em> </p></section><section> <h3><a name="Where_is_the_plugin-registry.xml.3F"></a>Where is the plugin-registry.xml?</h3> <p>From the settings.xml, you may enable it by setting <code><usePluginRegistry/></code> to true and the file will be in <code>~/.m2/plugin-registry.xml</code></p> -<p><i>General, Plugins and Lifecycle</i></p></section><section> +<p><em>General, Plugins and Lifecycle</em></p></section><section> <h3><a name="Is_there_a_way_to_specify_a_different_output_directory_without_having_to_edit_the_pom_or_configuration_file_each_time_I_do_a_build.3F"></a>Is there a way to specify a different output directory without having to edit the pom or configuration file each time I do a build?</h3> <p>Yes. You can make use of the pom's <code><properties></code> element to accomplish this.</p> <p>To do so, simply add the following fragment to your pom:</p> @@ -1021,7 +1021,7 @@ i.e. </project> </code></pre></div></section><section> <h3><a name="How_do_I_change_the_default_remote_repository.3F"></a>How do I change the default remote repository?</h3> -<p>Define in your POM a repository with “central” as the repository id.</p> +<p>Define in your POM a repository with central as the repository id.</p> <div class="source"><pre class="prettyprint linenums"><code><repositories> <repository> @@ -1033,8 +1033,8 @@ i.e. </repository> </repositories> </code></pre></div> -<p><i>Repositories</i></p></section><section> -<h3><a name="I_have_my_web.xml_in_my_customed_directory_layout_for_my_webapp.2C_but_why_am_I_getting_the_error_.E2.80.9CDeployment_descriptor_.3CPath.3E.5CWEB-INF.5Cweb.xml_does_not_exist.E2.80.9D.3F"></a>I have my web.xml in my customed directory layout for my webapp, but why am I getting the error “Deployment descriptor <code><Path>\WEB-INF\web.xml</code> does not exist”?</h3> +<p><em>Repositories</em></p></section><section> +<h3><a name="I_have_my_web.xml_in_my_customed_directory_layout_for_my_webapp.2C_but_why_am_I_getting_the_error_nullDeployment_descriptor_.3CPath.3E.5CWEB-INF.5Cweb.xml_does_not_existnull.3F"></a>I have my web.xml in my customed directory layout for my webapp, but why am I getting the error Deployment descriptor <code><Path>\WEB-INF\web.xml</code> does not exist?</h3> <p>You may specify the path of your web.xml in your webapp by configuring maven-war-plugin.</p> <div class="source"><pre class="prettyprint linenums"><code><build> @@ -1050,7 +1050,7 @@ i.e. </plugins> </build> </code></pre></div> -<p><i>Errors, Deployment</i> </p></section><section> +<p><em>Errors, Deployment</em> </p></section><section> <h3><a name="Is_it_possible_to_specify_multiple_.3Cmodule.3E.28s.29_in_a_POM_at_a_greater_depth_than_1_level.3F"></a>Is it possible to specify multiple <code><module></code>(s) in a POM at a greater depth than 1 level?</h3> <p>Yes. This can be done in two ways: 1. add the extra path in the top level POM, or 2. add extra parent poms at different levels, if approriate.</p> <p>For example, you have the following structure: @@ -1080,7 +1080,7 @@ Add the following at the top level POM:< <modules> </code></pre></div> <p>Both ways are effectively the same, but if you have that inheritance structure, the second gives a more natural grouping (eg, you can cd -into “B” and build all its subprojects only). +into B and build all its subprojects only). If you do the first solution, the children poms should have the following hint in the parent element:</p> <div class="source"><pre class="prettyprint linenums"><code class="language-<parent>"> ... @@ -1089,7 +1089,7 @@ If you do the first solution, the childr </parent> </code></pre></div> <p>The repository is still used if ../../pom.xml is not found or the versions don't match, but the hint makes it easier to use local modifications without installing the parent.  -<i>POM</i></p></section><section> +<em>POM</em></p></section><section> <h3><a name="How_to_list_all_goals_available_for_a_certain_plugin.3F"></a>How to list all goals available for a certain plugin?</h3> <p>We can use the describe goal of maven-projecthelp-plugin to list the goals available, see sample syntax below.</p> @@ -1097,12 +1097,12 @@ If you do the first solution, the childr </code></pre></div> <p>This would display all the goals and descriptions of the parameters used by maven-eclipse-plugin. \ -To get a quick overview about available mojos you can use the ‘help’ mojo which automatically gets generated in newer plugins.</p> +To get a quick overview about available mojos you can use the help mojo which automatically gets generated in newer plugins.</p> <div class="source"><pre class="prettyprint linenums"><code>mvn [pluginname]:help e.g. mvn eclipse:help </code></pre></div> -<p><i>Plugins and Lifecycle, IDEs</i></p></section><section> +<p><em>Plugins and Lifecycle, IDEs</em></p></section><section> <h3><a name="What_does_aggregator_mean_in_mojo.3F"></a>What does aggregator mean in mojo?</h3> <p>When a Mojo has a <code>@aggregator</code> expression, it means that It can only build the parent project of your multi-module-project, the one who has the packaging of pom. It can also give you values for the expression ${reactorProjects} where reactorProjects are the MavenProject references to the parent pom modules.</p></section><section> <h3><a name="Why_there_are_no_dependency_properties_in_Maven.3F"></a>Why there are no dependency properties in Maven?</h3> @@ -1111,11 +1111,11 @@ environment of the dependee, which is ba dependency - but that relies on the dependency specifying it.</p> <p>In the end, we give control to the actual POM doing the building, trying to use sensible defaults that minimise what needs to be specified, and allowing the use of artifact filters in the configuration of plugins.</p></section><section> -<h3><a name="How_do_I_prevent_including_JARs_in_WEB-INF.2Flib.3F_I_need_a_.E2.80.9Ccompile_only.E2.80.9D_scope"></a>How do I prevent including JARs in WEB-INF/lib? I need a “compile only” scope</h3> +<h3><a name="How_do_I_prevent_including_JARs_in_WEB-INF.2Flib.3F_I_need_a_nullcompile_onlynull_scope"></a>How do I prevent including JARs in WEB-INF/lib? I need a compile only scope</h3> <p>The scope you should use for this is provided. This indicates to Maven that the dependency will be provided at run time by its container or the JDK, for example.</p> <p>Dependencies with this scope will not be passed on transitively, nor will they be bundled in an package such as a WAR, or included in the runtime classpath.</p></section><section> <h3><a name="How_do_I_list_available_plugins.3F"></a>How do I list available plugins?</h3> -<p>The “Available Plugins” page lists them, and provides additional information to browse the Maven repository. See [http://maven.apache.org/plugins]</p></section><section> +<p>The Available Plugins page lists them, and provides additional information to browse the Maven repository. See [http://maven.apache.org/plugins]</p></section><section> <h3><a name="How_do_I_determine_what_version_of_a_plugin_I_am_using.3F"></a>How do I determine what version of a plugin I am using?</h3> <p>You can use the Maven Help Plugin's describe goal. For example, to find out the version of the install plugin: {noformat}mvn -Dplugin=install help:describe @@ -1124,8 +1124,8 @@ specified, and allowing the use of artif <p>There are currently 2 alternatives:</p> <ul> -<li>For use in a plugin written in Java, Beanshell or other Java-like scripting language, you can construct the Ant tasks <a class="externalLink" href="http://ant.apache.org/manual/antexternal.html">using the instructions given in the Ant documentation</a></li> -<li>If you have very small amounts of Ant script specific to your project, you can use the <a class="externalLink" href="http://maven.apache.org/plugins/maven-antrun-plugin/index.html">AntRun plugin</a>.</li> +<li>For use in a plugin written in Java, Beanshell or other Java-like scripting language, you can construct the Ant tasks <a href="http://ant.apache.org/manual/antexternal.html" class="externalLink">using the instructions given in the Ant documentation</a></li> +<li>If you have very small amounts of Ant script specific to your project, you can use the <a href="http://maven.apache.org/plugins/maven-antrun-plugin/index.html" class="externalLink">AntRun plugin</a>.</li> </ul></section><section> <h3><a name="Is_it_possible_to_create_my_own_directory_structure.3F"></a>Is it possible to create my own directory structure?</h3> <p>Absolutely yes!</p> @@ -1133,10 +1133,10 @@ specified, and allowing the use of artif <p>In addition, you may need to change the plugin configuration if you are not using plugin defaults for their files/directories.</p></section><section> <h3><a name="Where_is_the_source_code.3F_I_couldn.27t_seem_to_find_a_link_anywhere_on_the_Maven_site."></a>Where is the source code? I couldn't seem to find a link anywhere on the Maven site.</h3> <p>The source code can be found in subversion: [http://svn.apache.org/repos/asf/maven/components/trunk].</p> -<p>For more information, see <a class="externalLink" href="http://maven.apache.org/guides/development/guide-building-m2.html">Building Maven</a></p></section><section> +<p>For more information, see <a href="http://maven.apache.org/guides/development/guide-building-m2.html" class="externalLink">Building Maven</a></p></section><section> <h3><a name="Why_does_Maven_compile_my_test_classes_but_doesn.27t_run_them.3F"></a>Why does Maven compile my test classes but doesn't run them?</h3> <p>Tests are run by the surefire plugin. The surefire plugin can be configured to run certain test classes and you may have unintentionally done so by specifying a value to $ -{test}. Check your settings.xml and pom.xml for a property named “test” which would like this:</p> +{test}. Check your settings.xml and pom.xml for a property named test which would like this:</p> <div class="source"><pre class="prettyprint linenums"><code>... <properties> @@ -1171,7 +1171,7 @@ Your favorite IDE probably supports XSD </settings> </code></pre></div></section><section> <h3><a name="Maven_doesn.27t_work.2C_how_do_I_get_help.3F"></a>Maven doesn't work, how do I get help?</h3> -<p>We have compiled a list of available resources on the <a class="externalLink" href="http://maven.apache.org/users/getting-help.html">getting help page</a></p> +<p>We have compiled a list of available resources on the <a href="http://maven.apache.org/users/getting-help.html" class="externalLink">getting help page</a></p> <p>(#Dependencies, Design, Patterns & Best Practices)</p></section><section> <h3><a name="Where_to_find_the_source_code_for_org.apache.maven.model_package.3F"></a>Where to find the source code for org.apache.maven.model package?</h3> <p>The source for the model package is generated by modello. From your maven-model source, build it and you should able to see tha java files inside /target/generated-sources directory.</p></section><section> @@ -1217,11 +1217,11 @@ Your favorite IDE probably supports XSD </code></pre></div></section><section> <h3><a name="Unsupported_Protocol_Error_when_deploying_a_3rd_party_jar._What_should_I_do.3F"></a>Unsupported Protocol Error when deploying a 3rd party jar. What should I do?</h3> <p>When using deploy-deploy-file goal and encountered this error</p> -<p>“Error deploying artifact: Unsupported Protocol: ‘ftp’: Cannot find wagon which supports the requested protocol: ftp”</p> +<p>Error deploying artifact: Unsupported Protocol: ftp: Cannot find wagon which supports the requested protocol: ftp</p> <p>You only have to place the appropriate wagon provider to your <code>%M2_HOME%/lib</code> In this case the provider needed is ftp, so we have to place the wagon-ftp jar to the lib of your m2 installation.</p> <p>If the error description is something like</p> -<p>“Error deploying artifact: Unsupported Protocol: ‘ftp’: Cannot find wagon which supports the requested protocol: ftp org/apache/commons/net/ftp/FTP”</p> +<p>Error deploying artifact: Unsupported Protocol: ftp: Cannot find wagon which supports the requested protocol: ftp org/apache/commons/net/ftp/FTP</p> <p>Place also the commons-net jar to %M2_HOME%/lib.</p></section><section> <h3><a name="How_can_I_have_a_child_project_not_inherit_a_goal_.28like_install.29_from_the_parent.3F"></a>How can I have a child project not inherit a goal (like install) from the parent?</h3> <p>Use the <code>inherited</code> property. Set it to <code>false</code> in the plugin configuration. So for example, if you want your parent project to be installed but not your child, configure the install plugin like so:</p> @@ -1234,7 +1234,7 @@ In this case the provider needed is ftp, </plugin> </code></pre></div></section><section> <h3><a name="How_can_I_reference_windows_or_unix_environment_variables_in_my_POM.3F"></a>How can I reference windows or unix environment variables in my POM?</h3> -<p>Starting in maven <i>2.0.1</i>, you can reference windows and unix environment variables inside your pom.xml or settings.xml using an expression of the form: +<p>Starting in maven <em>2.0.1</em>, you can reference windows and unix environment variables inside your pom.xml or settings.xml using an expression of the form: <code>$\{env.VARNAME\}</code> So, if you wanted to reference your home directory environment variable, you might use: <code>$\{env.HOME\}</code></p></section><section> <h3><a name="How_do_I_know_which_phase_a_plug-in_is_associated_with.3F"></a>How do I know which phase a plug-in is associated with?</h3> @@ -1294,7 +1294,7 @@ there is already some discussion about t <type>war</type> </dependency> </code></pre></div></section><section> -<h3><a name="How_can_I_change_the_default_location_of_the_generated_jar_when_I_command_.E2.80.9Cmvn_package.E2.80.9D.3F"></a>How can I change the default location of the generated jar when I command “mvn package”?</h3> +<h3><a name="How_can_I_change_the_default_location_of_the_generated_jar_when_I_command_nullmvn_packagenull.3F"></a>How can I change the default location of the generated jar when I command mvn package?</h3> <p>By default, the location of the generated jar is in ${project.build.directory} or in your target directory. We can change this by configuring the outputDirectory of maven-jar-plugin.</p> @@ -1312,15 +1312,11 @@ meaning it is still in the state of deve <ol style="list-style-type: decimal"> <li> - <p>Change the version of your artifact. -For example, From 1.0-SNAPSHOT to 1.0</p> -</li> +For example, From 1.0-SNAPSHOT to 1.0</p></li> <li> - <p>Use the maven-release-plugin to prepare and create the official RELEASE version of your project artifact. -Please see [http://maven.apache.org/guides/mini/guide-releasing.html] for more reference.</p> -</li> +Please see [http://maven.apache.org/guides/mini/guide-releasing.html] for more reference.</p></li> </ol></section><section> <h3><a name="How_to_run_a_java_program_from_Maven.3F"></a>How to run a java program from Maven?</h3> <p>You may use the exec-maven-plugin for this. [http://mojo.codehaus.org/exec-maven-plugin/usage.html]</p></section><section> @@ -1328,7 +1324,7 @@ Please see [http://maven.apache.org/guid <p>You may use war:exploded goal for this.</p></section><section> <h3><a name="Is_there_any_variable_to_determine_what_version_of_an_artifact_was_deployed_after_the_deploy_step_runs.3F"></a>Is there any variable to determine what version of an artifact was deployed after the deploy step runs?</h3> <p>Use <code>$project.artifact.resolvedVersion</code>.</p></section><section> -<h3><a name="How_do_I_get_the_top_line_of_a_table_to_be_.E2.80.9Cheaders.E2.80.9D_for_that_column_in_APT.3F"></a>How do I get the top line of a table to be “headers” for that column in APT?</h3> +<h3><a name="How_do_I_get_the_top_line_of_a_table_to_be_nullheadersnull_for_that_column_in_APT.3F"></a>How do I get the top line of a table to be headers for that column in APT?</h3> <p>With the snapshot you can do:</p> <div class="source"><pre class="prettyprint linenums"><code>](]( header 1 ](]( header 2 ](]( header 3 ](]( @@ -1385,7 +1381,7 @@ More info about the assembly plugin can </project> </code></pre></div></section><section> <h3><a name="How_do_I_install_the_package_generated_by_the_assembly_plugin_to_be_installed_in_the_local_repository.3F"></a>How do I install the package generated by the assembly plugin to be installed in the local repository?</h3> -<p>Use the assembly plugin goal {{assembly:attach}} to install the generated package into the local repository. However, this feature is still in SVN. Please see <a class="externalLink" href="http://maven.apache.org/guides/development/guide-testing-development-plugins.html">Guide to Testing Development Plugins</a> for more info on how to use it.</p></section><section> +<p>Use the assembly plugin goal {{assembly:attach}} to install the generated package into the local repository. However, this feature is still in SVN. Please see <a href="http://maven.apache.org/guides/development/guide-testing-development-plugins.html" class="externalLink">Guide to Testing Development Plugins</a> for more info on how to use it.</p></section><section> <h3><a name="Is_it_possible_to_use_HashMap_as_configurable_parameter_in_a_plugin.3F_How_do_I_configure_that_in_pom.xml.3F"></a>Is it possible to use HashMap as configurable parameter in a plugin? How do I configure that in pom.xml?</h3> <p>Yes. Its possible to use a HashMap field as a parameter in your plugin. To use it, your pom configuration should look like this:</p> @@ -1395,14 +1391,14 @@ More info about the assembly plugin can </myMap> </code></pre></div></section><section> <h3><a name="How_do_I_setup_the_classpath_of_my_antrun_plugin_to_use_the_classpath_from_maven.3F"></a>How do I setup the classpath of my antrun plugin to use the classpath from maven?</h3> -<p>The maven classpaths are available as ant references when running your ant script. The ant reference names and some examples can be found here: <a class="externalLink" href="http://maven.apache.org/plugins/maven-antrun-plugin/classpaths.html">maven-antrun-plugin</a></p></section><section> +<p>The maven classpaths are available as ant references when running your ant script. The ant reference names and some examples can be found here: <a href="http://maven.apache.org/plugins/maven-antrun-plugin/classpaths.html" class="externalLink">maven-antrun-plugin</a></p></section><section> <h3><a name="Is_there_a_way_to_read_and_examine_the_contents_of_a_pom.xml_file_from_inside_an_application.3F"></a>Is there a way to read and examine the contents of a pom.xml file from inside an application?</h3> <p>Yes. You can use the org/apache/maven/model/io/xpp3/MavenXpp3Reader class from maven model to read a pom.</p></section><section> <h3><a name="Which_plugins_have_StarTeam_.28SCM.29_support.3F_How_do_they_differ.3F"></a>Which plugins have StarTeam (SCM) support? How do they differ?</h3> <p>maven-scm-plugin and maven-release-plugin support via maven-scm's API and maven-scm-provider-starteam. Release plugin is used to cut a new release of your project (label, build, assembly, deploy, etc.). SCM plugin, on the other hand, is for scm tasks.</p></section><section> <h3><a name="Is_there_a_way_to_use_the_deploy_phase_to_perform_some_tasks_without_maven_trying_to_install_the_artifact_to_a_maven_repository.3F"></a>Is there a way to use the deploy phase to perform some tasks without maven trying to install the artifact to a maven repository?</h3> -<p>If you run ‘mvn deploy’, the ‘maven-deploy-plugin’ kicks in. There's no flag that tells it not to upload the file. So you'd have to make a new lifecycle mapping/packaging for each <code><type></code> of artifact in your project. There's no way to ‘delete’ mojo's from the default lifecycle. What you could do is specify the remote repo as [file:///tmp]or something. Usually people want to ‘upload’ a war to the tomcat webapps dir, also known as deploying. That kind of deploying is not something m2 has a phase for.</p> -<p>What you can do is create a profile in the pom (or super pom), and add a task/mojo to the ‘install’ phase. For instance, you can have the antrun plugin copy the artifact to the tomcat directory (its location specified in settings.xml). The profile is named ‘dev’, so whenever you want to deploy a war, you just type ‘mvn install -Pdev’. Don't bind to the deploy phase, but to the install or package phase.</p></section><section> +<p>If you run mvn deploy, the maven-deploy-plugin kicks in. There's no flag that tells it not to upload the file. So you'd have to make a new lifecycle mapping/packaging for each <code><type></code> of artifact in your project. There's no way to delete mojo's from the default lifecycle. What you could do is specify the remote repo as [file:///tmp]or something. Usually people want to upload a war to the tomcat webapps dir, also known as deploying. That kind of deploying is not something m2 has a phase for.</p> +<p>What you can do is create a profile in the pom (or super pom), and add a task/mojo to the install phase. For instance, you can have the antrun plugin copy the artifact to the tomcat directory (its location specified in settings.xml). The profile is named dev, so whenever you want to deploy a war, you just type mvn install -Pdev. Don't bind to the deploy phase, but to the install or package phase.</p></section><section> <h3><a name="Repository_precedence"></a>Repository precedence</h3> <p>The repositories are searched through based in the order they are defined in your pom. The inherited repositories are always searched last. Note: You don't have to define the central repo (i.e. ibiblio).</p></section><section> @@ -1450,15 +1446,15 @@ Related document: [http://maven.apache.o <h3><a name="How_not_to_include_all_jar_files_from_parent_pom.3F"></a>How not to include all jar files from parent pom?</h3> <p>Use the right scope. If you don't want them to be included, specify the scope of your dependency as provided.</p></section><section> <h3><a name="How_to_make_Continuum_work_in_service_mode_when_an_Error_1067_is_reported.3F"></a>How to make Continuum work in service mode when an Error 1067 is reported?</h3> -<p>When using WinXP, Continuum works in command line but not in service mode and reports an “Error 1067”. This is due to the system path including spaces (e.g. “c:Program Files”). To fix this remove the %PATH% references in wrapper.conf.</p></section><section> +<p>When using WinXP, Continuum works in command line but not in service mode and reports an Error 1067. This is due to the system path including spaces (e.g. c:Program Files). To fix this remove the %PATH% references in wrapper.conf.</p></section><section> <h3><a name="Which_part_in_pom.xml_the_javadoc_plugin_should_be_configured.3F"></a>Which part in pom.xml the javadoc plugin should be configured?</h3> <p>It can be done in the plugins section of the pom or in the plugins section of the report section in the pom.</p> <p>Generally, you should configure it in the reporting section. Configuration there applies to both the site, and when run on the command line, and adding the plugin there adds the report to the generated site.</p> <p>Configuration in the build section is only used during the normal lifecycle or the command line invocation (e.g. javadoc:javadoc). Configuration should go there if you do not want the report on the site, or the configuration differs from what is on the site (e.g., some plugins have a fail build option).</p></section><section> <h3><a name="What_would_it_take_for_the_MOJO_one_to_get_out_of_the_sandbox.3F"></a>What would it take for the MOJO one to get out of the sandbox?</h3> <p>A full release, with active developers.</p></section><section> -<h3><a name="Using_xdoclet.2C_how_come_.E2.80.9C.E2.80.9D_does_not_work.3F"></a>Using xdoclet, how come “” does not work?</h3> -<p>For an example, let's say you have a Java source at src/main/java/com/junk/JunkBean.java. For it to compile correctly, it needs to have a “package com.junk;” in it. When XDoclet walks the source starting at “src/main”, it find a source file that identifies itself as being in package “com.junk” but it findsthe source in package “java.com.junk”. Since the two don't match, XDoclet assumes that there is a serious problem with the source file and ignores it.</p></section><section> +<h3><a name="Using_xdoclet.2C_how_come_nullnull_does_not_work.3F"></a>Using xdoclet, how come does not work?</h3> +<p>For an example, let's say you have a Java source at src/main/java/com/junk/JunkBean.java. For it to compile correctly, it needs to have a package com.junk; in it. When XDoclet walks the source starting at src/main, it find a source file that identifies itself as being in package com.junk but it findsthe source in package java.com.junk. Since the two don't match, XDoclet assumes that there is a serious problem with the source file and ignores it.</p></section><section> <h3><a name="How_do_I_indicate_array_types_in_a_MOJO_configuration.3F"></a>How do I indicate array types in a MOJO configuration?</h3> <div class="source"><pre class="prettyprint linenums"><code><tags> @@ -1511,11 +1507,11 @@ I think your choice is probably influenc </testResource> </testResources> </code></pre></div></section><section> -<h3><a name="How_can_I_stop_this_.E2.80.9CWARNING_While_downloading_artifactId-artifactId-version_This_artifact_has_been_relocated_to_groupId-artifactId-version.E2.80.9D.3F"></a>How can I stop this “WARNING While downloading artifactId-artifactId-version This artifact has been relocated to groupId-artifactId-version”?</h3> +<h3><a name="How_can_I_stop_this_nullWARNING_While_downloading_artifactId-artifactId-version_This_artifact_has_been_relocated_to_groupId-artifactId-versionnull.3F"></a>How can I stop this WARNING While downloading artifactId-artifactId-version This artifact has been relocated to groupId-artifactId-version?</h3> <p>It's probably because some other dependency has specified the dependency on artifactId:artifactId. It will only go away when that declaration is fixed in that POM.</p></section><section> <h3><a name="I_would_like_clarification_on_what_version_of_the_JDK_is_required_for_m2_-_particularly_with_respect_to_creating_Plugins."></a>I would like clarification on what version of the JDK is required for m2 - particularly with respect to creating Plugins.</h3> <p>1.4 is required to run m2 there're problems when using 1.5 features in plugins. People tried and failed because qdox (used for some mojo stuff doesn't support new 1.5 language)</p></section><section> -<h3><a name="i.27m_wondering_what_a_.E2.80.9Csnapshot.E2.80.9D_actually_is."></a>i'm wondering what a “snapshot” actually is.</h3> +<h3><a name="i.27m_wondering_what_a_nullsnapshotnull_actually_is."></a>i'm wondering what a snapshot actually is.</h3> <p>A snapshot is a development version. e.g, 2.0-SNAPSHOT is thestill-in-development future 2.0.If you want to use a snapshot, just use <code><version></code> , e.g. <code><version>2.0-SNAPSHOT</version></code> . But first you must ensure that you have access to the repository containing this version.</p></section><section> <h3><a name="Is_it_possible_that_if_I_do_mvn_eclipse_eclipse_goal_that_my_project_would_get_disconnected_from_the_subversion_repository.3F"></a>Is it possible that if I do mvn eclipse eclipse goal that my project would get disconnected from the subversion repository?</h3> <p>1.4 is required to run m2 there're problems when using 1.5 features in plugins. People tried and failed because qdox (used for some mojo stuff doesn't support new 1.5 language)</p></section><section> @@ -1558,12 +1554,12 @@ the repository containing this version. <h3><a name="How_do_I_determine_my_project.27s_transitive_dependencies.2C_and_if_needed.2C_exclude_a_particular__transitive_dependency.3F"></a>How do I determine my project's transitive dependencies, and if needed, exclude a particular transitive dependency?</h3> <p>To find out which of your dependencies is causing the problem, use -X on the mvn command line. If necessary, you can redirect the output -to a file with ‘> filename.txt’ .</p> +to a file with > filename.txt .</p> <p>Then add an exclusion to that dependency in your pom.xml. Here's a post with some examples of exclusions: [http://article.gmane.org/gmane.comp.jakarta.tapestry.devel/9103]</p></section><section> <h3><a name="If_two_versions_of_the_same_dependency_are_at_the_same_depth.2C_how_do_you_know_or_predict_which_version_will_be_used.3F"></a>If two versions of the same dependency are at the same depth, how do you know or predict which version will be used?</h3> -<p>The order in which dependencies are declared effectively becomes the tie-breaker when two dependency versions are declared at the same depth…so if:</p> +<p>The order in which dependencies are declared effectively becomes the tie-breaker when two dependency versions are declared at the same depthso if:</p> <div class="source"><pre class="prettyprint linenums"><code>A -> B, C B -> D (v2) @@ -1624,12 +1620,12 @@ and A declares the following: <p>To store stuff that is not in ibiblio. An example of this is your own stuff.</p></section><section> <h3><a name="Whenever_a_file_is_modified_in_a_maven_project_how_is_the_SNAPSHOT_jar_updated_in_the_remote_repository.3F"></a>Whenever a file is modified in a maven project how is the SNAPSHOT jar updated in the remote repository?</h3> <p>Using mvn deploy, after inserting proper section into your POM</p></section><section> -<h3><a name="Is_maven_.E2.80.98deploy.E2.80.99_goal_and_actually_copying_of_a_dependency_or_artifact_jar_to_remote_repository_same.3F"></a>Is maven ‘deploy’ goal and actually copying of a dependency or artifact jar to remote repository same?</h3> +<h3><a name="Is_maven_nulldeploynull_goal_and_actually_copying_of_a_dependency_or_artifact_jar_to_remote_repository_same.3F"></a>Is maven deploy goal and actually copying of a dependency or artifact jar to remote repository same?</h3> <p>Actually, simply copying the artifact to the repository is not the same as using deploy. The deploy goal will update various metadata files, create the md5 and sha1 checksum files, and can optionally create missing POM files etc along with actually copying the artifact file. So there is a significant difference between the copying the file and using deploy.</p></section><section> -<h3><a name="When_I_run_mvn_release:prepare.2C_I_get_a_build_failure_saying_.E2.80.9CUnable_to_tag_SCM.2C_File_.28.E2.80.A6.29_already_exists.E2.80.9D._However.2C_the_tag_does_not_exist._What_is_wrong.3F"></a>When I run mvn release:prepare, I get a build failure saying “Unable to tag SCM, File (…) already exists”. However, the tag does not exist. What is wrong?</h3> +<h3><a name="When_I_run_mvn_release:prepare.2C_I_get_a_build_failure_saying_nullUnable_to_tag_SCM.2C_File_.28null.29_already_existsnull._However.2C_the_tag_does_not_exist._What_is_wrong.3F"></a>When I run mvn release:prepare, I get a build failure saying Unable to tag SCM, File () already exists. However, the tag does not exist. What is wrong?</h3> <p>The full failure will look something like this: -‘/stuff/tags/example/pom.xml’</p> +/stuff/tags/example/pom.xml</p> <div class="source"><pre class="prettyprint linenums"><code>[INFO\] Tagging release with the label stuff-1.0.0... [INFO\] Executing: svn \--non-interactive copy \--file C:\DOCUME~1\G980143\LOCALS~1\Temp\maven-scm-1259783654.commit . http://www.example.com/subversion/repo/example/tags/stuff-1.0.0 @@ -1644,7 +1640,7 @@ Command output: svn: Commit failed (details follow): svn: File 'subversion/repo/example/tags/stuff-1.0.0/pom.xml' already exists </code></pre></div> -<p>This will only happen in Subversion 1.5.x, and is due to a “changed behavior” in Subversion 1.5.0 and upwards. Maven and Subversion people have at the time og writing not agreed upon who should fix it. A workaround is to downgrade Subversion to version 1.4.4 and use that. Another is to manually copy the trunk/release branch to the tags directory, commit the change and then edit the release.properties file to reflect the fact that tagging has been done.</p></section><section> +<p>This will only happen in Subversion 1.5.x, and is due to a changed behavior in Subversion 1.5.0 and upwards. Maven and Subversion people have at the time og writing not agreed upon who should fix it. A workaround is to downgrade Subversion to version 1.4.4 and use that. Another is to manually copy the trunk/release branch to the tags directory, commit the change and then edit the release.properties file to reflect the fact that tagging has been done.</p></section><section> <h3><a name="How_do_I_filter_resources_in_the_war.3F"></a>How do I filter resources in the war?</h3> <p>The best resource for filtering resources in the war can be found here: [http://maven.apache.org/plugins/maven-war-plugin/examples/adding-filtering-webresources.html]</p></section><section> @@ -1653,7 +1649,7 @@ svn: File 'subversion/repo/example/tags/ <h3><a name="What_would_be_the_appropriate_way_to_enable_inheritance_of_classes_in_the_test_hierarchy_across_modules_during_the_test-compile_phase_of_a_multi-pom_project.3F"></a>What would be the appropriate way to enable inheritance of classes in the test hierarchy across modules during the test-compile phase of a multi-pom project?</h3> <p>For information on this topic please visit: [http://maven.apache.org/guides/mini/guide-attached-tests.html]</p></section><section> <h3><a name="How_do_I_read_the_version_from_the_pom.xml_and_then_using_Java_display_the_version_on_my_application.3F"></a>How do I read the version from the pom.xml and then using Java display the version on my application?</h3> -<p>If you want to read a pom file, you can use the MavenXpp3Reader#read(… ). +<p>If you want to read a pom file, you can use the MavenXpp3Reader#read( ). But if you simply want to get the version of your currently running maven project inside your pom ( which is usually the case ), you can simply do:</p> <div class="source"><pre class="prettyprint linenums"><code>/** @@ -1675,15 +1671,15 @@ private String version; <p>I want to build a plugin with multiple goal, some goal might be aliases and call other goals. How do i do that in m2?</p></section><section> <h3><a name="Maven_Open_Source.21_How_do_I_download_the_source_code.3F"></a>Maven Open Source! How do I download the source code?</h3> <p>I've seen the link to the source code: [http://svn.apache.org/repos/asf/maven/components/trunk/]</p> -<p>but what is the easy way to download the source code. I can't find all the answers I need to understand in the documeentation (need more! so it will be usefull to get the source code locally to be able to do search etc…</p> +<p>but what is the easy way to download the source code. I can't find all the answers I need to understand in the documeentation (need more! so it will be usefull to get the source code locally to be able to do search etc</p> <p>I've just found the answer svn anonymous access: [http://maven.apache.org/source-repository.html];</p></section><section> <h3><a name="Why_do_I_get_java.lang.NoClassDefFoundError:_org.2Fcodehaus.2Fclassworlds.2FLauncher_when_I_try_to_execute_Maven.3F"></a>Why do I get java.lang.NoClassDefFoundError: org/codehaus/classworlds/Launcher when I try to execute Maven?</h3> -<p>This sometimes happens when $M2_HOME is not the same as your $PATH. That is, when ‘which mvn’ does not match $M2_HOME/bin/mvn.</p></section><section> +<p>This sometimes happens when $M2_HOME is not the same as your $PATH. That is, when which mvn does not match $M2_HOME/bin/mvn.</p></section><section> <h3><a name="How_to_encrypt_a_secure_password_that_includes_an_Ampersand"></a>How to encrypt a secure password that includes an Ampersand</h3> <p>If you want to <code>mvn --encrypt-password</code> a password with an ampersand you will get an error, e.g. <code>mvn --encrypt-password test&Password</code> On the one hand the ampersand has to be encoded as entity with &. On the other hand the ampersand has to be escaped for the command line. Result would be <code>mvn --encrypt-password test &Password</code> -Also a dollar sign $ has to be escaped for the command line.</p></section></section> +Also a dollar sign $ has to be escaped for the command line.</p></section></section></section> </main> </div>
[... 2 lines stripped ...]