Hi all,

I've been using the war plugin to package up a web app. However, to save
time, it would be great if the result had a consistent name so that we
could copy it directly into the Tomcat/webapps directory and have it
startup with the proper context path. 

In the call to the war plugin, I used the <warName> tag, and that works
just fine for my live build, which uses war:war. However, my dev build
profile uses war:exploded instead, and the <warName> doesn't seem to
have any effect. I tried using antrun, as below, but that doesn't seem
to have any effect either. When I run mvn -P dev clean package, the
output does claim to be executing this task (referred to by the ID
element, so I know it's not another antrun I've used), but the result is
still just an exploded war that has the standard maven name scheme of
artifactId-version.

        <plugin>
                <artifactId>maven-antrun-plugin</artifactId>
                <executions>
                <execution>
                        <id>RenameFinalDirectory</id>
                        <phase>package</phase> 
                        <goals>
                                <goal>run</goal>
                        </goals>
                        <configuration>
                                <tasks>
                                        <mkdir
dir="${project.build.directory}\${project.name}"/>
                                        <move
todir="${project.build.directory}\${project.name}">
                                                <fileset
dir="${project.build.directory}\${project.artifactId}-${project.version}
"/>
                                        </move>
                                </tasks>
                        </configuration>
                        </execution>
               </executions>
        </plugin>

Any suggestions on why this doesn't work, or what I might use instead?

-- 
This message may contain confidential, proprietary, or legally privileged 
information. No confidentiality or privilege is waived by any transmission to 
an unintended recipient. If you are not an intended recipient, please notify 
the sender and delete this message immediately. Any views expressed in this 
message are those of the sender, not those of any entity within the KBC 
Financial Products group of companies (together referred to as "KBC FP"). 

This message does not create any obligation, contractual or otherwise, on the 
part of KBC FP. It is not an offer (or solicitation of an offer) of, or a 
recommendation to buy or sell, any financial product. Any prices or other 
values included in this message are indicative only, and do not necessarily 
represent current market prices, prices at which KBC FP would enter into a 
transaction, or prices at which similar transactions may be carried on KBC FP's 
own books. The information contained in this message is provided "as is", 
without representations or warranties, express or implied, of any kind. Past 
performance is not indicative of future returns.


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

Reply via email to