Question

Here an snippet pom.xml

<build>
    <plugins>
      <plugin>
        <groupId>org.apache.maven.plugins</groupId>
        <artifactId>maven-war-plugin</artifactId>
        <version>2.2</version>
        <configuration>
          <webappDirectory>C:/Users/Tom/Desktop</webappDirectory>
        </configuration>
      </plugin>
    </plugins>
  </build>

It creates the war file to my target folder inside eclipse workspace. It should put the war folder to my desktop, but it only puts WEB-INF, META-INF folders there. Why?

Was it helpful?

Solution

You should use the outputDirectory option, not the webappDirectory

see http://maven.apache.org/plugins/maven-war-plugin/war-mojo.html

Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top