Hi,

I think we have two cases that are similar: Firstly, EJBs where only deployment descriptors are different. For this we use
+ parent
+- generic
+- specific1
+- specific2
All the sources are in generic/src/main/java.
parent has <packaging>pom</packaging> and <sourceDirectory>../generic/src/main/java</sourceDirectory>
specific1 and 2 have src/main/resources and different artifactIds.

The other one is about sharing JSP fragments between WARs, and we use the dependency plugin for that:
+ common
+ war-parent
+- war1
+- war2
+- war3
In war-parent we have:
    <dependency>
      <artifactId>common</artifactId>
      <scope>provided</scope>
    </dependency>
and
  <build>
    <plugins>
      <plugin>
        <artifactId>maven-dependency-plugin</artifactId>
        <version>2.1-SNAPSHOT</version>
        <executions>
          <execution>
            <id>expand common JSP fragments</id>
            <goals>
              <goal>unpack-dependencies</goal>
            </goals>
            <phase>generate-test-resources</phase>
            <configuration>
              <includeGroupIds>group.id</includeGroupIds>
              <includeArtifactIds>common</includeArtifactIds>
              <excludeTransitive>true</excludeTransitive>
              <includes>**/*.jsp*</includes>

<outputDirectory>${project.build.directory}/webapp</outputDirectory>
            </configuration>
          </execution>
        </executions>
      </plugin>
Likewise, you could unpack your resources to ${project.build.directory}/generates-resources and ${project.build.directory}/generated-sources.

HTH,

Stefan



Jean-Paul Vallée wrote:
Thanks, Jeff and manuel
I think i will have a look at overlays, your explainations seem to be what i
want to do.
But, is there a smarter way to do what i want, ie merge generic and specific
artifact when building the specific artifact.



--
best regards,

Stefan Seidel
software developer
________________________
VUB Printmedia GmbH
Chopinstraße 4
D-04103 Leipzig
Germany
tel.    +49 (341) 9 60 50 07
fax.    +49 (341) 9 60 50 92
mail.   [EMAIL PROTECTED]
web.    www.vub.de

HRB Köln 24015
UStID DE 122 649 251
GF Dr. Achim Preuss Neudorf,
Dr. Christian Preuss Neudorf

---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to