On 31 Oct 2008, Raffaele wrote:

> 
> Hi all,
> I have yet a question about correct using of WAR plugin, I'll try to
> describe my scenario:
> 
> Here it is a part of my project structure:
> 
> | configuration
> |- dev
> |-- WEB-INF
> |--- repository.xml 
> | src
> |- main
> |-- webapp
> |--- WEB-INF
> |---- repository.xml
> 
> As you can see, I have two respository.xml, one to be used during
> development releases and the other one to be used as default release.
> 
> I would like to control though profiles, dev releases and default releases,
> and so my pom (a part of it)is:
> 
> ...
> <profile>
>   <id>dev</id>
>     <build>
>       <plugins>
>         <plugin>
>         <groupId>org.apache.maven.plugins</groupId>
>         <artifactId>maven-war-plugin</artifactId>
>         <version>2.1-alpha-2</version>
>         <configuration>                      
>         <webResources>
>             <resource>
>               <directory>configuration/release</directory>  

Is this directory correct? Above you named it "configuration/dev" instead
of "configuration/release".

>             </resource>
>          </webResources>
>          </configuration>
>       </plugin>
>    </plugins>
>   </build>
> </profile>
> ...
> 
> After executing of mvn clean package -P dev I would like to see inside 
> |target
> |- my-webapp
> |-- WEB-INF
> |--- repository.xml (the profile dev version)
> 
> But I'm continueing see default repository.xml?


Is the profile active? You can verify this by executing "mvn -P dev
help:active-profiles".

hth,
- martin

Attachment: signature.asc
Description: PGP signature

Reply via email to