idea映射lib目录

Intellij IDEA配置maven插件在编译时映射到lib目录,否则需要手动导入

<groupId>com.springmvc.leon</groupId>
<artifactId>leon</artifactId>
<version>1.0-SNAPSHOT</version>
<packaging>war</packaging>


<!--配置Maven编译插件 -->
<build>
    <finalName>leon</finalName>
    <plugins>
        <plugin>
            <groupId>org.apache.maven.plugins</groupId>
            <artifactId>maven-compiler-plugin</artifactId>
            <version>3.5</version>
            <configuration>
                <source>1.8</source>
                <target>1.8</target>
                <compilerArguments>
                    <extdirs>src/main/webapp/WEB-INF/lib</extdirs><!-- 无此指定则需要手动把maven的jar包,映射到lib下面 -->
                    <bootclasspath>${java.home}/lib/rt.jar;${java.home}/lib/jce.jar</bootclasspath>
                </compilerArguments>
                <!-- 跳过测试用例 ,也不编译-->
                <skip>true</skip>
            </configuration>
        </plugin>
        <!-- 跳过测试用例 -->
        <plugin>
            <artifactId>maven-surefire-plugin</artifactId>
            <configuration>
                <skipTests>true</skipTests>
            </configuration>
        </plugin>
    </plugins>
</build>
posted @ 2020-04-10 09:48  zpk-aaron  阅读(1042)  评论(0编辑  收藏  举报