2023-02-01 10:37:18 +08:00
|
|
|
|
<?xml version="1.0" encoding="UTF-8"?>
|
|
|
|
|
<project xmlns="http://maven.apache.org/POM/4.0.0"
|
|
|
|
|
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
|
|
|
|
|
xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
|
|
|
|
|
<modelVersion>4.0.0</modelVersion>
|
|
|
|
|
|
|
|
|
|
<parent>
|
|
|
|
|
<groupId>org.springframework.boot</groupId>
|
|
|
|
|
<artifactId>spring-boot-starter-parent</artifactId>
|
|
|
|
|
<version>2.3.12.RELEASE</version>
|
|
|
|
|
</parent>
|
|
|
|
|
|
|
|
|
|
<groupId>com.ydool</groupId>
|
|
|
|
|
<artifactId>ydool-demo</artifactId>
|
|
|
|
|
<version>1.0-SNAPSHOT</version>
|
|
|
|
|
|
|
|
|
|
<properties>
|
|
|
|
|
<!-- jdk版本1.8 -->
|
|
|
|
|
<java.version>1.8</java.version>
|
|
|
|
|
<!-- maven-compiler-plugin插件版本,Java代码编译 -->
|
|
|
|
|
<maven.plugin.version>3.8.1</maven.plugin.version>
|
|
|
|
|
<!-- maven编译时指定编码UTF-8 -->
|
|
|
|
|
<maven.compiler.encoding>UTF-8</maven.compiler.encoding>
|
|
|
|
|
<maven.compiler.source>8</maven.compiler.source>
|
|
|
|
|
<maven.compiler.target>8</maven.compiler.target>
|
|
|
|
|
<!-- 项目统一字符集编码UTF-8 -->
|
|
|
|
|
<project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
|
|
|
|
|
<!-- 项目统一字符集编码UTF-8 -->
|
|
|
|
|
<project.reporting.outputEncoding>UTF-8</project.reporting.outputEncoding>
|
|
|
|
|
<!-- 项目统一设置版本号 -->
|
|
|
|
|
<gitegg.project.version>1.0-SNAPSHOT</gitegg.project.version>
|
|
|
|
|
<!-- SpringBoot版本号 -->
|
|
|
|
|
<spring.boot.version>2.3.12.RELEASE</spring.boot.version>
|
|
|
|
|
<!-- hutool版本号 -->
|
|
|
|
|
<hutool.version>5.8.11</hutool.version>
|
|
|
|
|
<!-- sa-token版本号-->
|
2023-02-03 09:13:30 +08:00
|
|
|
|
<sa-token.version>1.34.0</sa-token.version>
|
2023-02-01 10:37:18 +08:00
|
|
|
|
<!-- mysql数据库驱动 -->
|
|
|
|
|
<mysql.connector.version>8.0.17</mysql.connector.version>
|
|
|
|
|
<!-- 数据库连接池Druid -->
|
|
|
|
|
<druid.version>1.2.15</druid.version>
|
|
|
|
|
<!-- Mybatis Plus增强工具 -->
|
|
|
|
|
<mybatis.plus.version>3.4.3.1</mybatis.plus.version>
|
|
|
|
|
<!-- Knife4j Swagger2文档 -->
|
|
|
|
|
<knife4j.version>2.0.9</knife4j.version>
|
|
|
|
|
<!-- Lombok -->
|
|
|
|
|
<lombok.version>1.18.20</lombok.version>
|
|
|
|
|
<!-- Mybatis Plus代码生成器 -->
|
|
|
|
|
<mybatis.plus.gen.version>3.3.2</mybatis.plus.gen.version>
|
|
|
|
|
<!-- Mybatis Plus多表连接 -->
|
|
|
|
|
<mybatis.plus.join.version>1.2.4</mybatis.plus.join.version>
|
|
|
|
|
<org.mapstruct.version>1.4.2.Final</org.mapstruct.version>
|
|
|
|
|
|
|
|
|
|
<app.build.name>${project.artifactId}-${project.version}</app.build.name>
|
|
|
|
|
<app.build.prod>target/build</app.build.prod>
|
|
|
|
|
</properties>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
<dependencies>
|
|
|
|
|
<!-- Lombok 通过简单注解消除冗长代码 -->
|
|
|
|
|
<dependency>
|
|
|
|
|
<groupId>org.projectlombok</groupId>
|
|
|
|
|
<artifactId>lombok</artifactId>
|
|
|
|
|
<version>${lombok.version}</version>
|
|
|
|
|
</dependency>
|
|
|
|
|
|
|
|
|
|
<dependency>
|
|
|
|
|
<groupId>org.springframework.boot</groupId>
|
|
|
|
|
<artifactId>spring-boot-starter-web</artifactId>
|
|
|
|
|
<exclusions>
|
|
|
|
|
<exclusion>
|
|
|
|
|
<groupId>org.springframework.boot</groupId>
|
|
|
|
|
<artifactId>spring-boot-starter-tomcat</artifactId>
|
|
|
|
|
</exclusion>
|
|
|
|
|
<exclusion>
|
|
|
|
|
<artifactId>log4j-api</artifactId>
|
|
|
|
|
<groupId>org.apache.logging.log4j</groupId>
|
|
|
|
|
</exclusion>
|
|
|
|
|
<exclusion>
|
|
|
|
|
<artifactId>log4j-to-slf4j</artifactId>
|
|
|
|
|
<groupId>org.apache.logging.log4j</groupId>
|
|
|
|
|
</exclusion>
|
|
|
|
|
</exclusions>
|
|
|
|
|
</dependency>
|
|
|
|
|
|
|
|
|
|
<dependency>
|
|
|
|
|
<groupId>org.springframework.boot</groupId>
|
|
|
|
|
<artifactId>spring-boot-starter-undertow</artifactId>
|
|
|
|
|
</dependency>
|
|
|
|
|
|
|
|
|
|
<!-- spring-boot-starter-web 2.3.x开始不再默认引入,这里需要手动引入-->
|
|
|
|
|
<dependency>
|
|
|
|
|
<groupId>org.springframework.boot</groupId>
|
|
|
|
|
<artifactId>spring-boot-starter-validation</artifactId>
|
|
|
|
|
</dependency>
|
|
|
|
|
|
|
|
|
|
<dependency>
|
|
|
|
|
<groupId>org.springframework.boot</groupId>
|
|
|
|
|
<artifactId>spring-boot-starter-cache</artifactId>
|
|
|
|
|
</dependency>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
<dependency>
|
|
|
|
|
<groupId>net.sf.ehcache</groupId>
|
|
|
|
|
<artifactId>ehcache</artifactId>
|
|
|
|
|
</dependency>
|
|
|
|
|
|
|
|
|
|
<dependency>
|
|
|
|
|
<groupId>com.ibeetl</groupId>
|
|
|
|
|
<artifactId>beetl</artifactId>
|
|
|
|
|
<version>3.1.8.RELEASE</version>
|
|
|
|
|
</dependency>
|
|
|
|
|
|
|
|
|
|
<dependency>
|
|
|
|
|
<groupId>org.springframework.boot</groupId>
|
|
|
|
|
<artifactId>spring-boot-starter-thymeleaf</artifactId>
|
|
|
|
|
</dependency>
|
|
|
|
|
|
|
|
|
|
<!-- mysql数据库驱动 -->
|
|
|
|
|
<dependency>
|
|
|
|
|
<groupId>mysql</groupId>
|
|
|
|
|
<artifactId>mysql-connector-java</artifactId>
|
|
|
|
|
<version>${mysql.connector.version}</version>
|
|
|
|
|
</dependency>
|
|
|
|
|
|
|
|
|
|
<dependency>
|
|
|
|
|
<groupId>com.alibaba</groupId>
|
|
|
|
|
<artifactId>easyexcel</artifactId>
|
|
|
|
|
<version>2.2.10</version>
|
|
|
|
|
</dependency>
|
|
|
|
|
|
|
|
|
|
<!-- 数据库连接池 -->
|
|
|
|
|
<dependency>
|
|
|
|
|
<groupId>com.alibaba</groupId>
|
|
|
|
|
<artifactId>druid-spring-boot-starter</artifactId>
|
|
|
|
|
<version>${druid.version}</version>
|
|
|
|
|
</dependency>
|
|
|
|
|
|
|
|
|
|
<!-- Mybatis Plus增强工具 -->
|
|
|
|
|
<dependency>
|
|
|
|
|
<groupId>com.baomidou</groupId>
|
|
|
|
|
<artifactId>mybatis-plus-boot-starter</artifactId>
|
|
|
|
|
<version>${mybatis.plus.version}</version>
|
|
|
|
|
</dependency>
|
|
|
|
|
|
|
|
|
|
<dependency>
|
|
|
|
|
<groupId>com.github.yulichang</groupId>
|
|
|
|
|
<artifactId>mybatis-plus-join</artifactId>
|
|
|
|
|
<version>${mybatis.plus.join.version}</version>
|
|
|
|
|
</dependency>
|
|
|
|
|
|
|
|
|
|
<dependency>
|
|
|
|
|
<groupId>com.baomidou</groupId>
|
|
|
|
|
<artifactId>mybatis-plus-generator</artifactId>
|
|
|
|
|
<version>${mybatis.plus.gen.version}</version>
|
|
|
|
|
<exclusions>
|
|
|
|
|
<exclusion>
|
|
|
|
|
<groupId>com.baomidou</groupId>
|
|
|
|
|
<artifactId>mybatis-plus-extension</artifactId>
|
|
|
|
|
</exclusion>
|
|
|
|
|
</exclusions>
|
|
|
|
|
</dependency>
|
|
|
|
|
|
|
|
|
|
<!-- Swagger2 knife4j bom方式引入 -->
|
|
|
|
|
<dependency>
|
|
|
|
|
<groupId>com.github.xiaoymin</groupId>
|
|
|
|
|
<artifactId>knife4j-spring-boot-starter</artifactId>
|
|
|
|
|
<version>${knife4j.version}</version>
|
|
|
|
|
</dependency>
|
|
|
|
|
|
|
|
|
|
<!-- hutool工具类 -->
|
|
|
|
|
<dependency>
|
|
|
|
|
<groupId>cn.hutool</groupId>
|
|
|
|
|
<artifactId>hutool-all</artifactId>
|
|
|
|
|
<version>${hutool.version}</version>
|
|
|
|
|
</dependency>
|
|
|
|
|
|
|
|
|
|
<!-- sa-token -->
|
|
|
|
|
<dependency>
|
|
|
|
|
<groupId>cn.dev33</groupId>
|
|
|
|
|
<artifactId>sa-token-spring-boot-starter</artifactId>
|
|
|
|
|
<version>${sa-token.version}</version>
|
|
|
|
|
</dependency>
|
|
|
|
|
|
|
|
|
|
<dependency>
|
|
|
|
|
<groupId>org.mapstruct</groupId>
|
|
|
|
|
<artifactId>mapstruct</artifactId>
|
|
|
|
|
<version>${org.mapstruct.version}</version>
|
|
|
|
|
</dependency>
|
|
|
|
|
|
|
|
|
|
<dependency>
|
|
|
|
|
<groupId>org.mapstruct</groupId>
|
|
|
|
|
<artifactId>mapstruct-processor</artifactId>
|
|
|
|
|
<version>${org.mapstruct.version}</version>
|
|
|
|
|
</dependency>
|
|
|
|
|
|
|
|
|
|
<dependency>
|
|
|
|
|
<groupId>org.apache.httpcomponents</groupId>
|
|
|
|
|
<artifactId>httpclient</artifactId>
|
|
|
|
|
</dependency>
|
|
|
|
|
|
|
|
|
|
<dependency>
|
|
|
|
|
<groupId>com.google.code.gson</groupId>
|
|
|
|
|
<artifactId>gson</artifactId>
|
|
|
|
|
<version>2.8.0</version>
|
|
|
|
|
</dependency>
|
|
|
|
|
|
|
|
|
|
<dependency>
|
|
|
|
|
<groupId>org.aspectj</groupId>
|
|
|
|
|
<artifactId>aspectjweaver</artifactId>
|
|
|
|
|
</dependency>
|
|
|
|
|
|
|
|
|
|
<dependency>
|
|
|
|
|
<groupId>org.springframework.boot</groupId>
|
|
|
|
|
<artifactId>spring-boot-starter-test</artifactId>
|
|
|
|
|
</dependency>
|
|
|
|
|
|
|
|
|
|
<dependency>
|
|
|
|
|
<groupId>org.bytedeco</groupId>
|
|
|
|
|
<artifactId>javacv-platform</artifactId>
|
|
|
|
|
<version>1.5.7</version>
|
|
|
|
|
</dependency>
|
|
|
|
|
|
|
|
|
|
<dependency>
|
|
|
|
|
<groupId>com.aliyun</groupId>
|
|
|
|
|
<artifactId>aliyun-java-sdk-core</artifactId>
|
|
|
|
|
<version>4.0.6</version> <!-- 注:如提示报错,先升级基础包版,无法解决可联系技术支持 -->
|
|
|
|
|
</dependency>
|
|
|
|
|
|
|
|
|
|
<dependency>
|
|
|
|
|
<groupId>com.aliyun</groupId>
|
|
|
|
|
<artifactId>aliyun-java-sdk-dysmsapi</artifactId>
|
|
|
|
|
<version>1.1.0</version>
|
|
|
|
|
</dependency>
|
|
|
|
|
|
|
|
|
|
</dependencies>
|
|
|
|
|
|
|
|
|
|
<build>
|
|
|
|
|
<plugins>
|
|
|
|
|
<!-- 打JAR包 -->
|
|
|
|
|
<plugin>
|
|
|
|
|
<groupId>org.apache.maven.plugins</groupId>
|
|
|
|
|
<artifactId>maven-jar-plugin</artifactId>
|
|
|
|
|
<configuration>
|
|
|
|
|
<archive>
|
|
|
|
|
<manifest>
|
|
|
|
|
<addClasspath>true</addClasspath>
|
|
|
|
|
<!-- MANIFEST.MF 中 Class-Path 加入前缀 -->
|
|
|
|
|
<classpathPrefix>lib/</classpathPrefix>
|
|
|
|
|
<!-- jar包不包含唯一版本标识 -->
|
|
|
|
|
<useUniqueVersions>false</useUniqueVersions>
|
|
|
|
|
<!--指定入口类 需要改名 -->
|
|
|
|
|
<mainClass>xyz.grapehub.AppEntry</mainClass>
|
|
|
|
|
</manifest>
|
|
|
|
|
<manifestEntries>
|
|
|
|
|
<!--MANIFEST.MF 中 Class-Path 加入资源文件目录 -->
|
|
|
|
|
<Class-Path>./resources/</Class-Path>
|
|
|
|
|
</manifestEntries>
|
|
|
|
|
</archive>
|
|
|
|
|
<outputDirectory>${project.build.directory}</outputDirectory>
|
|
|
|
|
</configuration>
|
|
|
|
|
</plugin>
|
|
|
|
|
<!-- 该插件的作用是用于复制依赖的jar包到指定的文件夹里 -->
|
|
|
|
|
<plugin>
|
|
|
|
|
<groupId>org.apache.maven.plugins</groupId>
|
|
|
|
|
<artifactId>maven-dependency-plugin</artifactId>
|
|
|
|
|
<executions>
|
|
|
|
|
<execution>
|
|
|
|
|
<id>copy-dependencies</id>
|
|
|
|
|
<phase>package</phase>
|
|
|
|
|
<goals>
|
|
|
|
|
<goal>copy-dependencies</goal>
|
|
|
|
|
</goals>
|
|
|
|
|
<configuration>
|
|
|
|
|
<outputDirectory>${project.build.directory}/lib/</outputDirectory>
|
|
|
|
|
</configuration>
|
|
|
|
|
</execution>
|
|
|
|
|
</executions>
|
|
|
|
|
</plugin>
|
|
|
|
|
<!-- 该插件的作用是用于复制指定的文件 -->
|
|
|
|
|
<plugin>
|
|
|
|
|
<artifactId>maven-resources-plugin</artifactId>
|
|
|
|
|
<executions>
|
|
|
|
|
<execution>
|
|
|
|
|
<!-- 复制配置文件 -->
|
|
|
|
|
<id>copy-resources</id>
|
|
|
|
|
<phase>package</phase>
|
|
|
|
|
<goals>
|
|
|
|
|
<goal>copy-resources</goal>
|
|
|
|
|
</goals>
|
|
|
|
|
<configuration>
|
|
|
|
|
<resources>
|
|
|
|
|
<resource>
|
|
|
|
|
<directory>src/main/resources</directory>
|
|
|
|
|
<includes>
|
|
|
|
|
<include>*.properties</include>
|
|
|
|
|
<include>*.xml</include>
|
|
|
|
|
<include>*.yml</include>
|
|
|
|
|
</includes>
|
|
|
|
|
<excludes>
|
|
|
|
|
<exclude>*.jar</exclude>
|
|
|
|
|
</excludes>
|
|
|
|
|
</resource>
|
|
|
|
|
</resources>
|
|
|
|
|
<outputDirectory>${project.build.directory}/resources</outputDirectory>
|
|
|
|
|
</configuration>
|
|
|
|
|
</execution>
|
|
|
|
|
</executions>
|
|
|
|
|
</plugin>
|
|
|
|
|
<plugin>
|
|
|
|
|
<groupId>org.springframework.boot</groupId>
|
|
|
|
|
<artifactId>spring-boot-maven-plugin</artifactId>
|
|
|
|
|
<version>2.1.7.RELEASE</version>
|
|
|
|
|
<configuration>
|
|
|
|
|
<!--重写包含依赖,包含不存在的依赖,jar里没有pom里的依赖 -->
|
|
|
|
|
<includes>
|
|
|
|
|
<include>
|
|
|
|
|
<groupId>null</groupId>
|
|
|
|
|
<artifactId>null</artifactId>
|
|
|
|
|
</include>
|
|
|
|
|
</includes>
|
|
|
|
|
<layout>ZIP</layout>
|
|
|
|
|
<!--使用外部配置文件,jar包里没有资源文件 -->
|
|
|
|
|
<addResources>true</addResources>
|
|
|
|
|
<outputDirectory>${project.build.directory}/resources</outputDirectory>
|
|
|
|
|
</configuration>
|
|
|
|
|
|
|
|
|
|
<executions>
|
|
|
|
|
<execution>
|
|
|
|
|
<goals>
|
|
|
|
|
<goal>repackage</goal>
|
|
|
|
|
</goals>
|
|
|
|
|
|
|
|
|
|
<configuration>
|
|
|
|
|
<!--配置jar包特殊标识 配置后,保留原文件,生成新文件 *-run.jar -->
|
|
|
|
|
<!--配置jar包特殊标识 不配置,原文件命名为 *.jar.original,生成新文件 *.jar -->
|
|
|
|
|
<!--<classifier>run</classifier> -->
|
|
|
|
|
</configuration>
|
|
|
|
|
|
|
|
|
|
</execution>
|
|
|
|
|
</executions>
|
|
|
|
|
</plugin>
|
|
|
|
|
<!-- 对打包后的文件重新进行组装 -->
|
|
|
|
|
<plugin>
|
|
|
|
|
<groupId>org.apache.maven.plugins</groupId>
|
|
|
|
|
<artifactId>maven-antrun-plugin</artifactId>
|
|
|
|
|
<executions>
|
|
|
|
|
<execution>
|
|
|
|
|
<phase>package</phase>
|
|
|
|
|
<goals>
|
|
|
|
|
<goal>run</goal>
|
|
|
|
|
</goals>
|
|
|
|
|
<configuration>
|
|
|
|
|
<tasks>
|
|
|
|
|
|
|
|
|
|
<copy file="${project.basedir}/target/${app.build.name}.jar"
|
|
|
|
|
tofile="${app.build.prod}/xs_building_star.jar"/>
|
|
|
|
|
<copy file="${project.basedir}/bin/start.sh" tofile="${app.build.prod}/start.sh"/>
|
|
|
|
|
|
|
|
|
|
<!-- 复制资源文件 -->
|
|
|
|
|
<copy todir="${app.build.prod}">
|
|
|
|
|
<fileset dir="target/resources">
|
|
|
|
|
<include name="**/*.properties"/>
|
|
|
|
|
<include name="**/*.xml"/>
|
|
|
|
|
<include name="**/*.yml"/>
|
|
|
|
|
</fileset>
|
|
|
|
|
</copy>
|
|
|
|
|
|
|
|
|
|
<!-- 复制包文件 -->
|
|
|
|
|
<copy todir="${app.build.prod}/lib">
|
|
|
|
|
<fileset dir="target/lib"/>
|
|
|
|
|
</copy>
|
|
|
|
|
|
|
|
|
|
</tasks>
|
|
|
|
|
</configuration>
|
|
|
|
|
</execution>
|
|
|
|
|
</executions>
|
|
|
|
|
</plugin>
|
|
|
|
|
</plugins>
|
|
|
|
|
</build>
|
|
|
|
|
|
|
|
|
|
</project>
|