svn commit: r1602802 - /maven/plugins/trunk/maven-jar-plugin/src/main/java/org/apache/maven/plugin/jar/AbstractJarMojo.java
Author: khmarbaise Date: Mon Jun 16 06:08:03 2014 New Revision: 1602802 URL: http://svn.apache.org/r1602802 Log: [MJAR-167] - Fixed the logging information according to the type. Modified: maven/plugins/trunk/maven-jar-plugin/src/main/java/org/apache/maven/plugin/jar/AbstractJarMojo.java Modified: maven/plugins/trunk/maven-jar-plugin/src/main/java/org/apache/maven/plugin/jar/AbstractJarMojo.java URL: http://svn.apache.org/viewvc/maven/plugins/trunk/maven-jar-plugin/src/main/java/org/apache/maven/plugin/jar/AbstractJarMojo.java?rev=1602802r1=1602801r2=1602802view=diff == --- maven/plugins/trunk/maven-jar-plugin/src/main/java/org/apache/maven/plugin/jar/AbstractJarMojo.java (original) +++ maven/plugins/trunk/maven-jar-plugin/src/main/java/org/apache/maven/plugin/jar/AbstractJarMojo.java Mon Jun 16 06:08:03 2014 @@ -244,7 +244,7 @@ public abstract class AbstractJarMojo { if ( skipIfEmpty (!getClassesDirectory().exists() || getClassesDirectory().list().length 1 ) ) { -getLog().info( Skipping packaging of the test-jar ); +getLog().info( Skipping packaging of the + getType() ); } else {
svn commit: r1602931 - in /maven/plugins/trunk/maven-jar-plugin/src/site: apt/examples/attached-jar.apt.vm apt/examples/create-test-jar.apt.vm apt/examples/include-exclude.apt.vm apt/index.apt.vm apt/
Author: khmarbaise Date: Mon Jun 16 17:15:11 2014 New Revision: 1602931 URL: http://svn.apache.org/r1602931 Log: [MJAR-176] - Changed documentation according to the suggestions in the issue. Added: maven/plugins/trunk/maven-jar-plugin/src/site/apt/examples/attached-jar.apt.vm maven/plugins/trunk/maven-jar-plugin/src/site/apt/examples/create-test-jar.apt.vm maven/plugins/trunk/maven-jar-plugin/src/site/apt/examples/include-exclude.apt.vm Modified: maven/plugins/trunk/maven-jar-plugin/src/site/apt/index.apt.vm maven/plugins/trunk/maven-jar-plugin/src/site/apt/usage.apt.vm maven/plugins/trunk/maven-jar-plugin/src/site/site.xml Added: maven/plugins/trunk/maven-jar-plugin/src/site/apt/examples/attached-jar.apt.vm URL: http://svn.apache.org/viewvc/maven/plugins/trunk/maven-jar-plugin/src/site/apt/examples/attached-jar.apt.vm?rev=1602931view=auto == --- maven/plugins/trunk/maven-jar-plugin/src/site/apt/examples/attached-jar.apt.vm (added) +++ maven/plugins/trunk/maven-jar-plugin/src/site/apt/examples/attached-jar.apt.vm Mon Jun 16 17:15:11 2014 @@ -0,0 +1,70 @@ + -- + How to create an additional attached jar artifact from the project + -- + Karl Heinz Marbaise + -- + 2014-06-16 + -- + + ~~ Licensed to the Apache Software Foundation (ASF) under one + ~~ or more contributor license agreements. See the NOTICE file + ~~ distributed with this work for additional information + ~~ regarding copyright ownership. The ASF licenses this file + ~~ to you under the Apache License, Version 2.0 (the + ~~ License); you may not use this file except in compliance + ~~ with the License. You may obtain a copy of the License at + ~~ + ~~ http://www.apache.org/licenses/LICENSE-2.0 + ~~ + ~~ Unless required by applicable law or agreed to in writing, + ~~ software distributed under the License is distributed on an + ~~ AS IS BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY + ~~ KIND, either express or implied. See the License for the + ~~ specific language governing permissions and limitations + ~~ under the License. + + ~~ NOTE: For help with the syntax of this file, see: + ~~ http://maven.apache.org/doxia/references/apt-format.html + +How to create an additional attached jar artifact from the project + + Specify a list of fileset patterns to be included or excluded by adding + \includes\/\include\ or \excludes\/\exclude\ + and add a classifier in your pom.xml. + + Note: the jar-plugin must be defined in a new execution, otherwise it + will replace the default use of the jar-plugin instead of adding a second + artifact. The classifier is also required to create more than one artifact. + ++-+ +project + ... + build +plugins + ... + plugin +groupIdorg.apache.maven.plugins/groupId +artifactIdmaven-jar-plugin/artifactId +version${project.version}/version +executions + execution +phasepackage/phase +goals + goaljar/goal +/goals +configuration + classifierclient/classifier + includes +include**/service/*/include + /includes +/configuration + /execution +/executions + /plugin + ... +/plugins + /build + ... +/project ++-+ + Added: maven/plugins/trunk/maven-jar-plugin/src/site/apt/examples/create-test-jar.apt.vm URL: http://svn.apache.org/viewvc/maven/plugins/trunk/maven-jar-plugin/src/site/apt/examples/create-test-jar.apt.vm?rev=1602931view=auto == --- maven/plugins/trunk/maven-jar-plugin/src/site/apt/examples/create-test-jar.apt.vm (added) +++ maven/plugins/trunk/maven-jar-plugin/src/site/apt/examples/create-test-jar.apt.vm Mon Jun 16 17:15:11 2014 @@ -0,0 +1,125 @@ + -- + How to create a jar containing test classes + -- + Karl Heinz Marbaise + -- + 2014-06-16 + -- + + ~~ Licensed to the Apache Software Foundation (ASF) under one + ~~ or more contributor license agreements. See the NOTICE file + ~~ distributed with this work for additional information + ~~ regarding copyright ownership. The ASF licenses this file + ~~ to you under the Apache License, Version 2.0 (the + ~~ License); you may not use this file except in compliance + ~~ with the License. You may obtain a copy of the License at + ~~ + ~~ http://www.apache.org/licenses/LICENSE-2.0 + ~~ + ~~ Unless required by applicable law or agreed to in writing, + ~~ software distributed under the License is distributed on an + ~~ AS IS BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY + ~~ KIND, either express or implied. See the License for the + ~~ specific language governing permissions and limitations + ~~ under the License. + + ~~ NOTE: For help with the syntax of this file, see: + ~~
svn commit: r1602952 - /maven/plugins/trunk/maven-jar-plugin/src/site/apt/usage.apt.vm
Author: rfscholte Date: Mon Jun 16 18:32:13 2014 New Revision: 1602952 URL: http://svn.apache.org/r1602952 Log: Rewrite this page a bit, assuming this is the first time the reader uses Maven. Modified: maven/plugins/trunk/maven-jar-plugin/src/site/apt/usage.apt.vm Modified: maven/plugins/trunk/maven-jar-plugin/src/site/apt/usage.apt.vm URL: http://svn.apache.org/viewvc/maven/plugins/trunk/maven-jar-plugin/src/site/apt/usage.apt.vm?rev=1602952r1=1602951r2=1602952view=diff == --- maven/plugins/trunk/maven-jar-plugin/src/site/apt/usage.apt.vm (original) +++ maven/plugins/trunk/maven-jar-plugin/src/site/apt/usage.apt.vm Mon Jun 16 18:32:13 2014 @@ -47,35 +47,36 @@ Usage * How to build a JAR file - If the packaging of your project is set to 'jar', this plugin is executed - whenever it passes the package phase. The following is a simple example - of a project which should produce a 'jar' as an artifact. + When you want to create a JAR-file with Maven, you first have to create a pom.xml-file with at least the following content: +--+ project - ... + modelVersion4.0.0/modelVersion + groupIdcom.mycompany.project/groupId artifactIdcore/artifactId version1.0-SNAPSHOT/version - ... + !-- packagingjar/packaging -- /project +--+ - - The packing 'jar' type is not needed to mentioned, cause 'jar' is the default packaging type. - Apart from the above you need to create some real classes which should be located within - src/main/java. If you need some resources (for example property files) as well they - should be located in src/main/resources. Now we can create a 'jar' file by using the - command below: + + Since 'jar' is the default packaging type it is not required to set it in this case. + Apart from the above you will normally want some real java source files which should be located within + src/main/java. If you need extra resources on your classpath (for example property files) + they should be located in src/main/resources. + Now we can create a JAR-file by using the command below: +-+ mvn package +-+ - In your project's target directory you'll able to see the generated jar file which is named like: + The 'package' phase is always responsible for bundling all the files in the artifact, in this case a JAR-file. + + In your project's target directory you'll see the generated jar file which is named like: 'core-1.0-SNAPSHOT.jar'. The resulting 'jar' file contains the compiled java class files as well as - the files from src/main/resources which have been copied into target/classes. + the files from src/main/resources. Usually there is no need to mentioned the 'maven-jar-plugin' explicit cause it's bound to - the {{{http://maven.apache.org/guides/introduction/introduction-to-the-lifecycle.html}Maven Build Life Cylce}}. + the {{{http://maven.apache.org/guides/introduction/introduction-to-the-lifecycle.html}Maven Build Life Cycle}}. For full documentation, click {{{./plugin-info.html}here}}.
svn commit: r1602965 - /maven/site/trunk/content/xdoc/apache-resource-bundles/index.xml
Author: dennisl Date: Mon Jun 16 19:12:17 2014 New Revision: 1602965 URL: http://svn.apache.org/r1602965 Log: Set a proper title. Modified: maven/site/trunk/content/xdoc/apache-resource-bundles/index.xml Modified: maven/site/trunk/content/xdoc/apache-resource-bundles/index.xml URL: http://svn.apache.org/viewvc/maven/site/trunk/content/xdoc/apache-resource-bundles/index.xml?rev=1602965r1=1602964r2=1602965view=diff == --- maven/site/trunk/content/xdoc/apache-resource-bundles/index.xml (original) +++ maven/site/trunk/content/xdoc/apache-resource-bundles/index.xml Mon Jun 16 19:12:17 2014 @@ -20,7 +20,7 @@ -- document properties -titleIntroduction/title +titleApache Maven Resource Bundles/title authorOlivier Lamy/author /properties