pom.xml 5.4 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162
  1. <?xml version="1.0" encoding="UTF-8"?>
  2. <project xmlns="http://maven.apache.org/POM/4.0.0"
  3. xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
  4. xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
  5. <modelVersion>4.0.0</modelVersion>
  6. <groupId>com.caimei</groupId>
  7. <artifactId>caimei-mall</artifactId>
  8. <version>1.0-SNAPSHOT</version>
  9. <properties>
  10. <project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
  11. <maven.compiler.source>1.8</maven.compiler.source>
  12. <maven.compiler.target>1.8</maven.compiler.target>
  13. </properties>
  14. <parent>
  15. <groupId>org.springframework.boot</groupId>
  16. <artifactId>spring-boot-starter-parent</artifactId>
  17. <version>1.5.9.RELEASE</version>
  18. </parent>
  19. <dependencies>
  20. <!--spring Boot原始依赖-->
  21. <dependency>
  22. <groupId>org.springframework.boot</groupId>
  23. <artifactId>spring-boot-starter-web</artifactId>
  24. </dependency>
  25. <dependency>
  26. <groupId>org.springframework.boot</groupId>
  27. <artifactId>spring-boot-starter-test</artifactId>
  28. <scope>test</scope>
  29. </dependency>
  30. <!-- 添加mybatis的核心包 -->
  31. <dependency>
  32. <groupId>org.mybatis.spring.boot</groupId>
  33. <artifactId>mybatis-spring-boot-starter</artifactId>
  34. <version>1.3.1</version>
  35. </dependency>
  36. <!-- mysql的依赖 -->
  37. <dependency>
  38. <groupId>mysql</groupId>
  39. <artifactId>mysql-connector-java</artifactId>
  40. <version>5.1.21</version>
  41. </dependency>
  42. <dependency>
  43. <groupId>com.alibaba</groupId>
  44. <artifactId>fastjson</artifactId>
  45. <version>1.2.6</version>
  46. </dependency>
  47. <!-- 分页插件 -->
  48. <dependency>
  49. <groupId>com.github.pagehelper</groupId>
  50. <artifactId>pagehelper-spring-boot-starter</artifactId>
  51. <version>1.2.3</version>
  52. </dependency>
  53. <!--模板引擎-->
  54. <dependency>
  55. <groupId>org.springframework.boot</groupId>
  56. <artifactId>spring-boot-starter-thymeleaf</artifactId>
  57. </dependency>
  58. <!--允许不严格的html5格式出现-->
  59. <dependency>
  60. <groupId>net.sourceforge.nekohtml</groupId>
  61. <artifactId>nekohtml</artifactId>
  62. <version>1.9.22</version>
  63. </dependency>
  64. <!--springboot使用tomcat容器-->
  65. <dependency>
  66. <groupId>org.springframework.boot</groupId>
  67. <artifactId>spring-boot-starter-tomcat</artifactId>
  68. <scope>compile</scope>
  69. </dependency>
  70. <!--struts-->
  71. <dependency>
  72. <groupId>org.apache.struts</groupId>
  73. <artifactId>struts2-core</artifactId>
  74. <version>2.3.32</version>
  75. <exclusions>
  76. <exclusion>
  77. <groupId>javassist</groupId>
  78. <artifactId>javassist</artifactId>
  79. </exclusion>
  80. </exclusions>
  81. </dependency>
  82. <dependency>
  83. <groupId>com.caimei</groupId>
  84. <artifactId>caimei-search-moudle</artifactId>
  85. <version>1.0-SNAPSHOT</version>
  86. <scope>compile</scope>
  87. </dependency>
  88. </dependencies>
  89. <profiles>
  90. <profile>
  91. <id>dev</id>
  92. <properties>
  93. <!-- 环境标识,需要与配置文件的名称相对应 -->
  94. <activatedProperties>dev</activatedProperties>
  95. </properties>
  96. <activation>
  97. <!-- 默认环境 -->
  98. <activeByDefault>true</activeByDefault>
  99. </activation>
  100. </profile>
  101. <profile>
  102. <id>test</id>
  103. <properties>
  104. <activatedProperties>test</activatedProperties>
  105. </properties>
  106. </profile>
  107. <profile>
  108. <id>prod</id>
  109. <properties>
  110. <activatedProperties>prod</activatedProperties>
  111. </properties>
  112. </profile>
  113. </profiles>
  114. <build>
  115. <resources>
  116. <resource>
  117. <!--配置文件路径 -->
  118. <directory>src/main/resources</directory> <!--这里对应项目存放配置文件的目录-->
  119. <!--开启filtering功能 -->
  120. <filtering>true</filtering>
  121. </resource>
  122. <resource>
  123. <directory>src/main/resources/${activatedProperties}</directory>
  124. <filtering>true</filtering>
  125. </resource>
  126. </resources>
  127. <plugins>
  128. <plugin>
  129. <groupId>org.springframework.boot</groupId>
  130. <artifactId>spring-boot-maven-plugin</artifactId>
  131. <version>1.5.2.RELEASE</version>
  132. <configuration>
  133. <mainClass>com.caimei.StartApplication</mainClass><!--springboot启动类目录-->
  134. </configuration>
  135. <executions>
  136. <execution>
  137. <goals>
  138. <!--创建一个自动可执行的jar或war文件 -->
  139. <goal>repackage</goal>
  140. </goals>
  141. </execution>
  142. </executions>
  143. </plugin>
  144. </plugins>
  145. </build>
  146. </project>