pom.xml中配置插件的作用


pom.xml里面的配置代码

<build>
    <plugins>
        <plugin>
            <groupId>org.apache.tomcat.maven</groupId>
            <artifactId>tomcat7-maven-plugin</artifactId>
            <configuration>
                <path>/</path>
                <port>8080</port>
            </configuration>
        </plugin>
    </plugins>
</build>

  

 

这样我们运行项目的时候就不用在使用本地的tomcat,直接在pom.xml所在的目录下打开命令窗口(shift+目录下右键菜单),执行mvn tomcat:run就可以运行项目。


免责声明!

本站转载的文章为个人学习借鉴使用,本站对版权不负任何法律责任。如果侵犯了您的隐私权益,请联系本站邮箱yoyou2525@163.com删除。



 
粤ICP备18138465号  © 2018-2025 CODEPRJ.COM