Maven报错:Error assembling WAR: webxml attribute is required (or pre-existing WEB-INF/web.xml

运行Maven install时报错:

[ERROR] Failed to execute goal org.apache.maven.plugins:maven-war-plugin:2.2:war (default-war) on project MavenFoo: Error assembling WAR: webxml attribute is required (or pre-existing WEB-INF/web.xml if executing in update mode) -> [Help 1]

[ERROR] 
[ERROR] To see the full stack trace of the errors, re-run Maven with the -e switch.
[ERROR] Re-run Maven using the -X switch to enable full debug logging.
[ERROR] 
[ERROR] For more information about the errors and possible solutions, please read the following articles:

[ERROR] [Help 1] http://cwiki.apache.org/confluence/display/MAVEN/MojoExecutionException

解决方法:

main下新增目录与web.xml文件

Maven报错:Error assembling WAR: webxml attribute is required (or pre-existing WEB-INF/web.xml_第1张图片

你可能感兴趣的:(maven)