1

Possible Duplicate:
Maven multi-module project - copying all “package” JARS from submodules into parent/target/

I have an pom structure:

project1
    |
    |______ pom.xml
    |______ module 1
    |          |_____ pom.xml
    |          |_____ dist
    |                  |_____ bin
    |                  |_____ lib
    |______ module 2
    |          |_____ pom.xml
    |          |_____ dist
    |                  |_____ bin
    |                  |_____ lib
    |______ dist
    |         |____ bin
    |         |____ lib


Requirements:
     +  When build each module, bundle file will be copied to its' dist/bin and dependencies copied to its' dist/lib
     + When build project1, bundle file of each module will be copied to project1/dist/bin and dependencies of all modules copied to project/dist/lib

Can we achieve this??? If it can, how we do it???

Community
  • 1
  • 1
Vijay
  • 11
  • 1
  • 3

1 Answers1

2

Just take a look here: https://github.com/khmarbaise/maven-copy-example . The only thing i changed is not to use a a folder like dist i use target/dist in the maven style.

khmarbaise
  • 92,914
  • 28
  • 189
  • 235