mvn command wrong in documentation to create a war file

Description

In section it says the following:

1.3.3. Deploying and testing

To build and deploy call mvn package in your project directory and copy the hibernate-
tutorial.war file into your Tomcat webapps directory.

But, to build a war file, you need to do the following with Maven.

mvn war:war

Activity

Brett MeyerMarch 7, 2014 at 5:30 PM

Bulk closing rejected tickets in "resolved" state.

Brian LavenderMarch 28, 2011 at 11:22 PM

Yes, I would change the pom.xml file to war. I did not know about this until today. I am a beginner with Maven. When I used "mvn war:war" it worked, so that is why I submitted it.

<modelVersion>4.0.0</modelVersion>
<groupId>org.hibernate.tutorials</groupId>
<packaging>war</packaging>
<artifactId>hibernate-tutorial</artifactId>
<version>1.0.0-SNAPSHOT</version>
<name>First Hibernate Tutorial</name>

Steve EbersoleMarch 28, 2011 at 1:46 PM

Actually, for sure that's not true, unless their documentation is incorrect also: http://maven.apache.org/plugins/maven-war-plugin/usage.html

Steve EbersoleMarch 28, 2011 at 1:45 PM

Even if the packaging is set to war? You sure about that?

Rejected

Details

Assignee

Reporter

Components

Affects versions

Priority

Created March 27, 2011 at 11:28 AM
Updated March 7, 2014 at 5:30 PM
Resolved March 28, 2011 at 1:46 PM