maven系列-maven报错Cannot detect Web Project version

**maven报错Cannot detect Web Project version. Please specify version of Web Project through Maven project property
. E.g.: 3.0 **
租金装了一个ubuntu系统试试水,在myeclipse15创建中创建maven项目完了后pom中报上面的错,一下是解决方法,
首先你要在build path里面修改你的项目的web version,现在至少都是3.0了,修改以后还需要修改你的jdk版本为1.8,然后在你的pom中指定的webversion

<properties>
        <webVersion>3.0webVersion>
properties>

之后加入一下代码:

在pom中加入

<build>
        <plugins>
            <plugin>
                <artifactId>maven-war-pluginartifactId>
                <version>2.4version>
                <configuration>
                    <version>3.0version>
                configuration>
            plugin>
        plugins>
    build>

那是因为项目未指定maven war编译插件的错误

你可能感兴趣的:(maven)