pom.xml 8.0 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310
  1. <project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
  2. xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/maven-v4_0_0.xsd">
  3. <modelVersion>4.0.0</modelVersion>
  4. <groupId>com.jfinal</groupId>
  5. <artifactId>haimingsi</artifactId>
  6. <version>4.8</version>
  7. <packaging>jar</packaging>
  8. <name>haimingsi</name>
  9. <url>http://jfinal.com/club</url>
  10. <properties>
  11. <project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
  12. <maven.compiler.encoding>UTF-8</maven.compiler.encoding>
  13. </properties>
  14. <!-- 使用阿里 maven 库 -->
  15. <repositories>
  16. <repository>
  17. <id>ali-maven</id>
  18. <url>http://maven.aliyun.com/nexus/content/groups/public</url>
  19. <releases>
  20. <enabled>true</enabled>
  21. </releases>
  22. <snapshots>
  23. <enabled>true</enabled>
  24. <updatePolicy>always</updatePolicy>
  25. <checksumPolicy>fail</checksumPolicy>
  26. </snapshots>
  27. </repository>
  28. </repositories>
  29. <dependencies>
  30. <!-- jfinal -->
  31. <dependency>
  32. <groupId>com.jfinal</groupId>
  33. <artifactId>jfinal</artifactId>
  34. <version>4.8</version>
  35. </dependency>
  36. <!-- jfinal-undertow 开发、部署一体化 web 服务器 -->
  37. <dependency>
  38. <groupId>com.jfinal</groupId>
  39. <artifactId>jfinal-undertow</artifactId>
  40. <version>2.0</version>
  41. </dependency>
  42. <!-- 开发 WebSockets 时开启下面的依赖 -->
  43. <!--
  44. <dependency>
  45. <groupId>io.undertow</groupId>
  46. <artifactId>undertow-websockets-jsr</artifactId>
  47. <version>2.0.28.Final</version>
  48. </dependency>
  49. -->
  50. <!-- junit 单元测试 -->
  51. <dependency>
  52. <groupId>junit</groupId>
  53. <artifactId>junit</artifactId>
  54. <version>3.8.1</version>
  55. <scope>test</scope>
  56. </dependency>
  57. <!-- 避免控制台输出如下提示信息:
  58. SLF4J: Failed to load class "org.slf4j.impl.StaticLoggerBinder".
  59. 项目中实际上用不到这个 jar 包
  60. 注意:eclipse 下可以将 scope 设置为 provided
  61. -->
  62. <dependency>
  63. <groupId>org.slf4j</groupId>
  64. <artifactId>slf4j-nop</artifactId>
  65. <version>1.7.29</version>
  66. <!-- 打包前改成 provided,此处使用 compile 仅为支持 IDEA -->
  67. <scope>compile</scope>
  68. </dependency>
  69. <!-- druid 数据源连接池 -->
  70. <dependency>
  71. <groupId>com.alibaba</groupId>
  72. <artifactId>druid</artifactId>
  73. <version>1.0.29</version>
  74. </dependency>
  75. <!-- fastjson json 转换 -->
  76. <dependency>
  77. <groupId>com.alibaba</groupId>
  78. <artifactId>fastjson</artifactId>
  79. <version>1.2.58</version>
  80. </dependency>
  81. <!-- log4j 日志 -->
  82. <dependency>
  83. <groupId>log4j</groupId>
  84. <artifactId>log4j</artifactId>
  85. <version>1.2.17</version>
  86. </dependency>
  87. <!-- mysql 驱动 -->
  88. <dependency>
  89. <groupId>mysql</groupId>
  90. <artifactId>mysql-connector-java</artifactId>
  91. <version>5.1.44</version>
  92. </dependency>
  93. <!-- cos 文件上传 -->
  94. <dependency>
  95. <groupId>com.jfinal</groupId>
  96. <artifactId>cos</artifactId>
  97. <version>2019.8</version>
  98. </dependency>
  99. <!-- ehcache 缓存 -->
  100. <dependency>
  101. <groupId>net.sf.ehcache</groupId>
  102. <artifactId>ehcache-core</artifactId>
  103. <version>2.6.11</version>
  104. </dependency>
  105. <!-- 邮件发送 -->
  106. <dependency>
  107. <groupId>commons-codec</groupId>
  108. <artifactId>commons-codec</artifactId>
  109. <version>1.9</version>
  110. </dependency>
  111. <!-- 邮件发送 -->
  112. <dependency>
  113. <groupId>org.apache.commons</groupId>
  114. <artifactId>commons-email</artifactId>
  115. <version>1.2</version>
  116. </dependency>
  117. <!-- jsoup 过滤恶意数据提交 -->
  118. <dependency>
  119. <groupId>org.jsoup</groupId>
  120. <artifactId>jsoup</artifactId>
  121. <version>1.9.2</version>
  122. </dependency>
  123. <!-- joda-time 日期、时间变换 -->
  124. <dependency>
  125. <groupId>joda-time</groupId>
  126. <artifactId>joda-time</artifactId>
  127. <version>2.9.3</version>
  128. </dependency>
  129. <!-- cron4j 任务调度 -->
  130. <dependency>
  131. <groupId>it.sauronsoftware.cron4j</groupId>
  132. <artifactId>cron4j</artifactId>
  133. <version>2.2.5</version>
  134. </dependency>
  135. <!-- zxing 二维码生成 -->
  136. <dependency>
  137. <groupId>com.google.zxing</groupId>
  138. <artifactId>javase</artifactId>
  139. <version>3.2.1</version>
  140. </dependency>
  141. <!-- https://mvnrepository.com/artifact/org.apache.commons/commons-lang3 -->
  142. <dependency>
  143. <groupId>org.apache.commons</groupId>
  144. <artifactId>commons-lang3</artifactId>
  145. <version>3.4</version>
  146. </dependency>
  147. <dependency>
  148. <groupId>org.projectlombok</groupId>
  149. <artifactId>lombok</artifactId>
  150. <version>1.18.12</version>
  151. <scope>provided</scope>
  152. </dependency>
  153. <!-- 阿里云短信jar包 start -->
  154. <dependency>
  155. <groupId>com.aliyun</groupId>
  156. <artifactId>aliyun-java-sdk-dysmsapi</artifactId>
  157. <version>1.0.0</version>
  158. </dependency>
  159. <dependency>
  160. <groupId>com.aliyun</groupId>
  161. <artifactId>aliyun-java-sdk-core</artifactId>
  162. <version>2.4.2</version>
  163. </dependency>
  164. <dependency>
  165. <groupId>com.aliyun</groupId>
  166. <artifactId>aliyun-java-sdk-sms</artifactId>
  167. <version>3.0.0-rc1</version>
  168. </dependency>
  169. <dependency>
  170. <groupId>com.alibaba</groupId>
  171. <artifactId>fastjson</artifactId>
  172. <version>1.2.15</version>
  173. </dependency>
  174. <!-- 阿里云短信jar包 end-->
  175. <!-- poi excel 上传下载 -->
  176. <!-- 表格导入导出jar包 -->
  177. <dependency>
  178. <groupId>org.apache.poi</groupId>
  179. <artifactId>poi</artifactId>
  180. <version>3.9</version>
  181. </dependency>
  182. <dependency>
  183. <groupId>org.apache.poi</groupId>
  184. <artifactId>poi-ooxml</artifactId>
  185. <version>3.9</version>
  186. </dependency>
  187. <!--
  188. <dependency>
  189. <groupId>fop</groupId>
  190. <artifactId>fop</artifactId>
  191. <version>0.20.5</version>
  192. <exclusions>
  193. <exclusion>
  194. <artifactId>xalan</artifactId>
  195. <groupId>xalan</groupId>
  196. </exclusion>
  197. </exclusions>
  198. </dependency>
  199. -->
  200. </dependencies>
  201. <build>
  202. <plugins>
  203. <plugin>
  204. <groupId>org.apache.maven.plugins</groupId>
  205. <artifactId>maven-compiler-plugin</artifactId>
  206. <version>3.6.1</version>
  207. <configuration>
  208. <source>1.8</source>
  209. <target>1.8</target>
  210. <encoding>UTF-8</encoding>
  211. <!-- java8 保留参数名编译参数 -->
  212. <compilerArgument>-parameters</compilerArgument>
  213. <compilerArguments><verbose /></compilerArguments>
  214. </configuration>
  215. </plugin>
  216. <!--
  217. jar 包中的配置文件优先级高于 config 目录下的 "同名文件"
  218. 因此,打包时需要排除掉 jar 包中来自 src/main/resources 目录的
  219. 配置文件,否则部署时 config 目录中的同名配置文件不会生效
  220. -->
  221. <plugin>
  222. <groupId>org.apache.maven.plugins</groupId>
  223. <artifactId>maven-jar-plugin</artifactId>
  224. <version>2.6</version>
  225. <configuration>
  226. <excludes>
  227. <!-- **/* 前缀用法,可以匹配所有路径,例如:**/*.txt -->
  228. <exclude>*.txt</exclude>
  229. <exclude>*.xml</exclude>
  230. <exclude>*.properties</exclude>
  231. </excludes>
  232. </configuration>
  233. </plugin>
  234. <!--
  235. 使用 mvn clean package 打包
  236. 更多配置可参考官司方文档:http://maven.apache.org/plugins/maven-assembly-plugin/single-mojo.html
  237. -->
  238. <plugin>
  239. <groupId>org.apache.maven.plugins</groupId>
  240. <artifactId>maven-assembly-plugin</artifactId>
  241. <version>3.1.0</version>
  242. <executions>
  243. <execution>
  244. <id>make-assembly</id>
  245. <phase>package</phase>
  246. <goals>
  247. <goal>single</goal>
  248. </goals>
  249. <configuration>
  250. <!-- 打包生成的文件名 -->
  251. <finalName>${project.artifactId}</finalName>
  252. <!-- jar 等压缩文件在被打包进入 zip、tar.gz 时是否压缩,设置为 false 可加快打包速度 -->
  253. <recompressZippedFiles>false</recompressZippedFiles>
  254. <!-- 打包生成的文件是否要追加 package.xml 中定义的 id 值 -->
  255. <appendAssemblyId>true</appendAssemblyId>
  256. <!-- 指向打包描述文件 package.xml -->
  257. <descriptors>
  258. <descriptor>package.xml</descriptor>
  259. </descriptors>
  260. <!-- 打包结果输出的基础目录 -->
  261. <outputDirectory>${project.build.directory}/</outputDirectory>
  262. </configuration>
  263. </execution>
  264. </executions>
  265. </plugin>
  266. </plugins>
  267. </build>
  268. </project>