Packaging practices under Eclipse

Source: Internet
Author: User

Premise:

Configure the package related plug-in, look at the packaging of the results to add different plugin, installed good m2eclipse.

The following steps take the packing of the war package as an example.

Steps:
    1. such as: Right-click, select Run As or Debug as to select Maven Build. The difference between the following two is that the first one will pop up an interface for you to select the previous build goal as the build goal, and the second will let you enter goal to complete the build.
    2. Enter: Package at goals and click Run to execute.
Description
    1. There are many ways maven can be packaged, so refer to the blog that was reproduced in the previous article: http://www.cnblogs.com/lzxianren/p/4904980.html
    2. If you need to skip the test, enter it at goals: Package-dmaven.test.skip=true or package-dskiptests, the difference is

      -dskiptests, does not execute the test case, but compiles the test case class to generate the corresponding class file to target/test-classes;
      -dmaven.test.skip=true, do not execute test cases, nor compile test case classes;

    3. If you still need clean, add clean at the front.
    4. MAVEN goals can have multiple, will be executed one after the other, so the above is said nonsense ...
Problem:
    1. Disable Maven warning Message-"Selected war files include a web-inf/web.xml which will is ignored" modify the version of the War pack plugin. Specific reference: Stack Overflow
Reference:
    1. Maven Packaging without Test (skip tests)
    2. The difference between-dskiptests and-dmaven.test.skip=true in maven
    3. Guide to Creating assemblies

Packaging practices under Eclipse

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.