Prevent war file from being copied to .m2/repository when running mvn clean install

Johan

We have a multi-module Maven project and we typically run mvn clean install to build everything. Preferably, we'd like to keep it this way.

What we would like to do is prevent projects with packaging war (that are using the maven-war-plugin) to copy their generated war files to the ~/.m2/repository folder. How can we achieve this?

Tunaki

You can skip the execution of the maven-install-plugin inside each of your war projects, using the skip attribute. It is this plugin that is responsible for copying the produced artifact into the local repository.

<plugin>
    <artifactId>maven-install-plugin</artifactId>
    <version>2.5.2</version>
    <configuration>
        <skip>true</skip>
    </configuration>
</plugin>

Collected from the Internet

Please contact [email protected] to delete if infringement.

edited at
0

Comments

0 comments
Login to comment

Related

From Dev

Connection reset error - when running mvn clean install to run features

From Dev

Is there a very effective method to prevent a .jpg file for being copied from a page?

From Dev

Prevent session from being replicated when JSESSIONID cookie copied

From Dev

Context.xml not coming to WAR on mvn clean install

From Dev

Prevent line numbers from being copied to clipboard

From Dev

How to prevent part of HTML text from being copied when copying adjacent?

From Dev

How to prevent part of HTML text from being copied when copying adjacent?

From Dev

Will switching branches while running mvn clean install affect maven?

From Dev

Mvn clean install error

From Dev

How to prevent binary file folder also being copied to output dir?

From Dev

Can I prevent object from being copied by std::memcpy?

From Dev

Why 'mvn install' war projects?

From Dev

Run "mvn clean install" in Eclipse

From Dev

Use of mvn clean -e install

From Dev

file is not being completely copied

From Dev

CNAME file not being copied to root output when publishing Pelican blog

From Dev

Upgrade of Jenkins from UI when running as war

From Dev

'mvn clean install': why does 'clean' run after 'install'?

From Dev

Prevent strings from being interpreted as a file handle

From Dev

Prevent a function or a file from being run with nose?

From Dev

Prevent a file from being recreated or overwritten

From Dev

Prevent file from being uploaded(windows)

From Dev

Prevent a function or a file from being run with nose?

From Dev

mvn clean install not able to resolve class

From Dev

mvn clean install doens't find package

From Dev

mvn clean install Could not find artifact

From Dev

maven -P option not working with mvn clean install

From Dev

Unit tests pass when ran separately in Eclipse but fail during mvn clean install

From Dev

Running maven multi-module failsafe tasks independently from mvn clean package

Related Related

  1. 1

    Connection reset error - when running mvn clean install to run features

  2. 2

    Is there a very effective method to prevent a .jpg file for being copied from a page?

  3. 3

    Prevent session from being replicated when JSESSIONID cookie copied

  4. 4

    Context.xml not coming to WAR on mvn clean install

  5. 5

    Prevent line numbers from being copied to clipboard

  6. 6

    How to prevent part of HTML text from being copied when copying adjacent?

  7. 7

    How to prevent part of HTML text from being copied when copying adjacent?

  8. 8

    Will switching branches while running mvn clean install affect maven?

  9. 9

    Mvn clean install error

  10. 10

    How to prevent binary file folder also being copied to output dir?

  11. 11

    Can I prevent object from being copied by std::memcpy?

  12. 12

    Why 'mvn install' war projects?

  13. 13

    Run "mvn clean install" in Eclipse

  14. 14

    Use of mvn clean -e install

  15. 15

    file is not being completely copied

  16. 16

    CNAME file not being copied to root output when publishing Pelican blog

  17. 17

    Upgrade of Jenkins from UI when running as war

  18. 18

    'mvn clean install': why does 'clean' run after 'install'?

  19. 19

    Prevent strings from being interpreted as a file handle

  20. 20

    Prevent a function or a file from being run with nose?

  21. 21

    Prevent a file from being recreated or overwritten

  22. 22

    Prevent file from being uploaded(windows)

  23. 23

    Prevent a function or a file from being run with nose?

  24. 24

    mvn clean install not able to resolve class

  25. 25

    mvn clean install doens't find package

  26. 26

    mvn clean install Could not find artifact

  27. 27

    maven -P option not working with mvn clean install

  28. 28

    Unit tests pass when ran separately in Eclipse but fail during mvn clean install

  29. 29

    Running maven multi-module failsafe tasks independently from mvn clean package

HotTag

Archive