pom.xml 5.1 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132
  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. <parent>
  6. <groupId>org.springframework.boot</groupId>
  7. <artifactId>spring-boot-starter-parent</artifactId>
  8. <version>3.4.2</version>
  9. </parent>
  10. <modelVersion>4.0.0</modelVersion>
  11. <groupId>net.mingsoft</groupId>
  12. <artifactId>ms-mcms</artifactId>
  13. <version>6.0.0</version>
  14. <name>${project.groupId}:${project.artifactId}</name>
  15. <!-- 打包war包 -->
  16. <properties>
  17. <java.version>17</java.version>
  18. <project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
  19. </properties>
  20. <packaging>jar</packaging>
  21. <dependencies>
  22. <dependency>
  23. <groupId>net.mingsoft</groupId>
  24. <artifactId>ms-base</artifactId>
  25. <version>3.0.0</version>
  26. </dependency>
  27. <dependency>
  28. <groupId>net.mingsoft</groupId>
  29. <artifactId>ms-basic</artifactId>
  30. <version>3.0.0.2</version>
  31. </dependency>
  32. <dependency>
  33. <groupId>net.mingsoft</groupId>
  34. <artifactId>ms-mdiy</artifactId>
  35. <version>3.0.0.1</version>
  36. </dependency>
  37. <dependency>
  38. <groupId>net.mingsoft</groupId>
  39. <artifactId>store-client</artifactId>
  40. <version>3.0.0.2</version>
  41. </dependency>
  42. <dependency>
  43. <groupId>com.github.oshi</groupId>
  44. <artifactId>oshi-core</artifactId>
  45. <version>6.2.2</version>
  46. </dependency>
  47. </dependencies>
  48. <build>
  49. <finalName>${project.artifactId}</finalName>
  50. <resources>
  51. <resource>
  52. <directory>src/main/webapp</directory>
  53. <!--打包生产jar包推荐启用下面配置-->
  54. <!--打包生产war包不启用下面配置-->
  55. <excludes>
  56. <!-- 可以避免将静态资源打入jar包中,方便生产实时修改静态资源文件-->
  57. <!-- 打包生产建议并手动将static、html、upload、template复制到生产 -->
  58. <!--<exclude>static/</exclude>
  59. <exclude>html/</exclude>
  60. <exclude>upload/</exclude>
  61. <exclude>template/</exclude>-->
  62. <!-- 如果生产需要实时修改WEB-INF/下的页面可,启用这行并手动将项目中的WEB-INF目录复制到运行环境 -->
  63. <!-- <exclude>WEB-INF/</exclude> -->
  64. </excludes>
  65. </resource>
  66. <resource>
  67. <directory>src/main/resources</directory>
  68. </resource>
  69. <resource>
  70. <directory>src/main/java</directory>
  71. <excludes>
  72. <exclude>**/*.java</exclude>
  73. </excludes>
  74. </resource>
  75. </resources>
  76. <plugins>
  77. <plugin>
  78. <groupId>org.springframework.boot</groupId>
  79. <artifactId>spring-boot-maven-plugin</artifactId>
  80. <configuration>
  81. <mainClass>net.mingsoft.MSApplication</mainClass>
  82. <executable>true</executable>
  83. <includeSystemScope>true</includeSystemScope>
  84. </configuration>
  85. </plugin>
  86. <plugin>
  87. <groupId>org.apache.maven.plugins</groupId>
  88. <artifactId>maven-compiler-plugin</artifactId>
  89. <configuration>
  90. <source>${java.version}</source>
  91. <target>${java.version}</target>
  92. <encoding>${project.build.sourceEncoding}</encoding>
  93. <showDeprecation>true</showDeprecation>
  94. <showWarnings>true</showWarnings>
  95. </configuration>
  96. </plugin>
  97. <!-- 结合(resources》resource》excludes的配置使用 -->
  98. <!-- 打包出的结构 http://doc.mingsoft.net/server/huan-jing-pei-zhi/jarbu-shu.html#%E7%9B%AE%E5%BD%95%E7%BB%93%E6%9E%84-->
  99. <!-- 打包war包时,注释掉此插件-->
  100. <plugin>
  101. <artifactId>maven-assembly-plugin</artifactId>
  102. <version>3.1.1</version>
  103. <executions>
  104. <execution>
  105. <id>build-package</id>
  106. <phase>package</phase>
  107. <goals>
  108. <goal>single</goal>
  109. </goals>
  110. <configuration>
  111. <finalName>${project.artifactId}</finalName>
  112. <descriptors>
  113. <descriptor>assembly.xml</descriptor>
  114. </descriptors>
  115. </configuration>
  116. </execution>
  117. </executions>
  118. </plugin>
  119. </plugins>
  120. <defaultGoal>compile</defaultGoal>
  121. </build>
  122. </project>