Markdown博文大赛开启中国云计算大会最新议题5月问答又送C币咯!做Hadoop工程师,冲击40万年薪游戏和图形开发研讨会
MAVEN: Error assembling WAR: webxml attribute is required
分类:Maven
maven
环境:MyEclipse2015 CI+Maven3
使用Maven创建一个Web project(创建方法参考《如何用Maven创建web项目(具体步骤)》),执行maven install时出现错误。
[INFO] ————————————————————————
[INFO] BUILD FAILURE[INFO] ————————————————————————[INFO] Total time: 3.152 s[INFO] Finished at: 2015-05-19T16:41:50+08:00[INFO] Final Memory: 9M/21M[INFO] ————————————————————————[ERROR] Failed to execute goal org.apache.maven.plugins:maven-war-plugin:2.4:war (default-war) on project TestWebApp: 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]
原因:目录/src/main/webapp/WEB-INF/下没有web.xml文件;
解决方案:在该目录下新建文件web.xml
效果:成功
上一篇MAVEN Dynamic Web Module 3.0 requires Java 1.6 or newer.下一篇MAVEN:Failure to transfer org.codehaus.plexus:plexus-io:jar:2.4.1
顶0踩0
主题推荐猜你在找
查看评论
* 以上用户言论只代表其个人观点,,不代表CSDN网站的观点或立场
核心技术类目
自己选择的路,跪着也要把它走完。