<?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-dependencies</artifactId>
        <version>3.1.5</version>
        <relativePath/>
    </parent>

    <groupId>top.charles7c.continew</groupId>
    <artifactId>continew-starter-dependencies</artifactId>
    <version>${revision}</version>
    <packaging>pom</packaging>

    <name>${project.artifactId}</name>
    <description>ContiNew Starter 依赖模块</description>
    <url>https://github.com/Charles7c/continew-starter</url>
    <licenses>
        <license>
            <name>GNU LESSER GENERAL PUBLIC LICENSE</name>
            <url>http://www.gnu.org/licenses/lgpl.html</url>
        </license>
    </licenses>
    <developers>
        <developer>
            <id>charles7c</id>
            <name>Charles7c</name>
            <email>charles7c@126.com</email>
            <roles>
                <role>Creator</role>
                <role>Java Development Engineer</role>
            </roles>
            <timezone>+8</timezone>
            <url>https://github.com/Charles7c</url>
        </developer>
        <developer>
            <id>bull-bcls</id>
            <name>Bull-BCLS</name>
            <email>Tomcat416@163.com</email>
            <roles>
                <role>Java Development Engineer</role>
            </roles>
            <timezone>+8</timezone>
            <url>https://github.com/Bull-BCLS</url>
        </developer>
    </developers>
    <scm>
        <url>https://github.com/Charles7c/continew-starter</url>
        <connection>scm:git:git@github.com:Charles7c/continew-starter.git</connection>
        <developerConnection>scm:git:git@github.com:Charles7c/continew-starter.git</developerConnection>
    </scm>

    <properties>
        <revision>1.1.0-SNAPSHOT</revision>
        <just-auth.version>1.16.5</just-auth.version>
        <sa-token.version>1.37.0</sa-token.version>
        <mybatis-plus.version>3.5.4.1</mybatis-plus.version>
        <dynamic-datasource.version>4.2.0</dynamic-datasource.version>
        <p6spy.version>3.9.1</p6spy.version>
        <redisson.version>3.24.3</redisson.version>
        <sms4j.version>3.0.4</sms4j.version>
        <easy-captcha.version>1.6.2</easy-captcha.version>
        <easy-excel.version>3.3.2</easy-excel.version>
        <knife4j.version>4.3.0</knife4j.version>
        <ttl.version>2.14.4</ttl.version>
        <ip2region.version>3.1.5.1</ip2region.version>
        <hutool.version>5.8.23</hutool.version>
    </properties>

    <dependencyManagement>
        <dependencies>
            <!-- Just Auth（开箱即用的整合第三方登录的开源组件，脱离繁琐的第三方登录 SDK，让登录变得 So easy!） -->
            <dependency>
                <groupId>me.zhyd.oauth</groupId>
                <artifactId>JustAuth</artifactId>
                <version>${just-auth.version}</version>
            </dependency>
            <dependency>
                <groupId>com.xkcoding.justauth</groupId>
                <artifactId>justauth-spring-boot-starter</artifactId>
                <version>1.4.0</version>
                <exclusions>
                    <exclusion>
                        <groupId>cn.hutool</groupId>
                        <artifactId>hutool-core</artifactId>
                    </exclusion>
                    <exclusion>
                        <groupId>me.zhyd.oauth</groupId>
                        <artifactId>JustAuth</artifactId>
                    </exclusion>
                </exclusions>
            </dependency>

            <!-- Sa-Token（轻量级 Java 权限认证框架，让鉴权变得简单、优雅） -->
            <dependency>
                <groupId>cn.dev33</groupId>
                <artifactId>sa-token-spring-boot3-starter</artifactId>
                <version>${sa-token.version}</version>
            </dependency>

            <!-- Sa-Token 整合 JWT -->
            <dependency>
                <groupId>cn.dev33</groupId>
                <artifactId>sa-token-jwt</artifactId>
                <version>${sa-token.version}</version>
                <exclusions>
                    <exclusion>
                        <groupId>cn.hutool</groupId>
                        <artifactId>hutool-all</artifactId>
                    </exclusion>
                </exclusions>
            </dependency>

            <!-- MyBatis Plus（MyBatis 的增强工具，在 MyBatis 的基础上只做增强不做改变，简化开发、提高效率） -->
            <dependency>
                <groupId>com.baomidou</groupId>
                <artifactId>mybatis-plus-spring-boot3-starter</artifactId>
                <version>${mybatis-plus.version}</version>
            </dependency>

            <!-- Dynamic Datasource（基于 Spring Boot 的快速集成多数据源的启动器） -->
            <dependency>
                <groupId>com.baomidou</groupId>
                <artifactId>dynamic-datasource-spring-boot3-starter</artifactId>
                <version>${dynamic-datasource.version}</version>
            </dependency>

            <!-- P6Spy（SQL 性能分析组件） -->
            <dependency>
                <groupId>p6spy</groupId>
                <artifactId>p6spy</artifactId>
                <version>${p6spy.version}</version>
            </dependency>

            <!-- Redisson（不仅仅是一个 Redis Java 客户端） -->
            <dependency>
                <groupId>org.redisson</groupId>
                <artifactId>redisson-spring-boot-starter</artifactId>
                <version>${redisson.version}</version>
            </dependency>

            <!-- SMS4J（短信聚合框架，轻松集成多家短信服务，解决接入多个短信 SDK 的繁琐流程） -->
            <dependency>
                <groupId>org.dromara.sms4j</groupId>
                <artifactId>sms4j-spring-boot-starter</artifactId>
                <version>${sms4j.version}</version>
            </dependency>

            <!-- Easy Captcha（Java 图形验证码，支持 gif、中文、算术等类型，可用于 Java Web、JavaSE 等项目） -->
            <dependency>
                <groupId>com.github.whvcse</groupId>
                <artifactId>easy-captcha</artifactId>
                <version>${easy-captcha.version}</version>
            </dependency>

            <!-- Easy Excel（一个基于 Java 的、快速、简洁、解决大文件内存溢出的 Excel 处理工具） -->
            <dependency>
                <groupId>com.alibaba</groupId>
                <artifactId>easyexcel</artifactId>
                <version>${easy-excel.version}</version>
            </dependency>

            <!-- Knife4j（前身是 swagger-bootstrap-ui，集 Swagger2 和 OpenAPI3 为一体的增强解决方案） -->
            <dependency>
                <groupId>com.github.xiaoymin</groupId>
                <artifactId>knife4j-dependencies</artifactId>
                <version>${knife4j.version}</version>
                <type>pom</type>
                <scope>import</scope>
            </dependency>

            <!-- TTL（线程间传递 ThreadLocal，异步执行时上下文传递的解决方案） -->
            <dependency>
                <groupId>com.alibaba</groupId>
                <artifactId>transmittable-thread-local</artifactId>
                <version>${ttl.version}</version>
            </dependency>

            <!-- 第三方封装 Ip2region（离线 IP 数据管理框架和定位库，支持亿级别的数据段，10 微秒级别的查询性能，提供了许多主流编程语言的 xdb 数据管理引擎的实现） -->
            <dependency>
                <groupId>net.dreamlu</groupId>
                <artifactId>mica-ip2region</artifactId>
                <version>${ip2region.version}</version>
            </dependency>

            <!-- Hutool（小而全的 Java 工具类库，通过静态方法封装，降低相关 API 的学习成本，提高工作效率，使 Java 拥有函数式语言般的优雅，让 Java 语言也可以“甜甜的”） -->
            <dependency>
                <groupId>cn.hutool</groupId>
                <artifactId>hutool-all</artifactId>
                <version>${hutool.version}</version>
            </dependency>

            <!-- ContiNew Starter 依赖 -->
            <!-- 扩展模块 - CRUD -->
            <dependency>
                <groupId>top.charles7c.continew</groupId>
                <artifactId>continew-starter-extension-crud</artifactId>
                <version>${revision}</version>
            </dependency>

            <!-- 认证模块 - JustAuth -->
            <dependency>
                <groupId>top.charles7c.continew</groupId>
                <artifactId>continew-starter-auth-justauth</artifactId>
                <version>${revision}</version>
            </dependency>

            <!-- 认证模块 - SaToken -->
            <dependency>
                <groupId>top.charles7c.continew</groupId>
                <artifactId>continew-starter-auth-satoken</artifactId>
                <version>${revision}</version>
            </dependency>

            <!-- 数据访问模块 - MyBatis Plus -->
            <dependency>
                <groupId>top.charles7c.continew</groupId>
                <artifactId>continew-starter-data-mybatis-plus</artifactId>
                <version>${revision}</version>
            </dependency>

            <!-- 缓存模块 - Redisson -->
            <dependency>
                <groupId>top.charles7c.continew</groupId>
                <artifactId>continew-starter-cache-redisson</artifactId>
                <version>${revision}</version>
            </dependency>

            <!-- 消息模块 - SMS -->
            <dependency>
                <groupId>top.charles7c.continew</groupId>
                <artifactId>continew-starter-messaging-sms</artifactId>
                <version>${revision}</version>
            </dependency>

            <!-- 消息模块 - 邮件 -->
            <dependency>
                <groupId>top.charles7c.continew</groupId>
                <artifactId>continew-starter-messaging-mail</artifactId>
                <version>${revision}</version>
            </dependency>

            <!-- 验证码模块 - 图形验证码 -->
            <dependency>
                <groupId>top.charles7c.continew</groupId>
                <artifactId>continew-starter-captcha-graphic</artifactId>
                <version>${revision}</version>
            </dependency>

            <!-- 文件处理模块 - Excel -->
            <dependency>
                <groupId>top.charles7c.continew</groupId>
                <artifactId>continew-starter-file-excel</artifactId>
                <version>${revision}</version>
            </dependency>

            <!-- 存储模块 - 本地存储 -->
            <dependency>
                <groupId>top.charles7c.continew</groupId>
                <artifactId>continew-starter-storage-local</artifactId>
                <version>${revision}</version>
            </dependency>

            <!-- 日志模块 - HttpTracePro（Spring Boot Actuator HttpTrace 定制增强版） -->
            <dependency>
                <groupId>top.charles7c.continew</groupId>
                <artifactId>continew-starter-log-httptrace-pro</artifactId>
                <version>${revision}</version>
            </dependency>

            <!-- 日志模块 - 公共模块 -->
            <dependency>
                <groupId>top.charles7c.continew</groupId>
                <artifactId>continew-starter-log-common</artifactId>
                <version>${revision}</version>
            </dependency>

            <!-- API 文档模块 -->
            <dependency>
                <groupId>top.charles7c.continew</groupId>
                <artifactId>continew-starter-api-doc</artifactId>
                <version>${revision}</version>
            </dependency>

            <!-- JSON 模块 - Jackson -->
            <dependency>
                <groupId>top.charles7c.continew</groupId>
                <artifactId>continew-starter-json-jackson</artifactId>
                <version>${revision}</version>
            </dependency>

            <!-- 核心模块 -->
            <dependency>
                <groupId>top.charles7c.continew</groupId>
                <artifactId>continew-starter-core</artifactId>
                <version>${revision}</version>
            </dependency>
        </dependencies>
    </dependencyManagement>

    <build>
        <plugins>
            <plugin>
                <groupId>org.codehaus.mojo</groupId>
                <artifactId>flatten-maven-plugin</artifactId>
                <version>1.5.0</version>
                <inherited>false</inherited>
                <executions>
                    <execution>
                        <!-- Create an effective POM (with versions expanded) for the CLI and documentation -->
                        <id>flatten-effective-pom</id>
                        <phase>process-resources</phase>
                        <goals>
                            <goal>flatten</goal>
                        </goals>
                        <configuration>
                            <updatePomFile>false</updatePomFile>
                            <outputDirectory>${project.build.directory}/effective-pom</outputDirectory>
                            <flattenedPomFilename>continew-starter-dependencies.xml</flattenedPomFilename>
                            <flattenMode>oss</flattenMode>
                            <pomElements>
                                <dependencyManagement>expand</dependencyManagement>
                                <pluginManagement>expand</pluginManagement>
                                <properties>remove</properties>
                                <repositories>remove</repositories>
                            </pomElements>
                        </configuration>
                    </execution>
                    <execution>
                        <!-- Flatten and simplify our own POM for install/deploy -->
                        <id>flatten</id>
                        <phase>process-resources</phase>
                        <goals>
                            <goal>flatten</goal>
                        </goals>
                        <configuration>
                            <updatePomFile>true</updatePomFile>
                            <flattenMode>bom</flattenMode>
                            <pomElements>
                                <parent>expand</parent>
                                <properties>keep</properties>
                                <pluginManagement>keep</pluginManagement>
                                <repositories>remove</repositories>
                            </pomElements>
                        </configuration>
                    </execution>
                    <execution>
                        <id>flatten-clean</id>
                        <phase>clean</phase>
                        <goals>
                            <goal>clean</goal>
                        </goals>
                    </execution>
                </executions>
            </plugin>
            <plugin>
                <groupId>org.codehaus.mojo</groupId>
                <artifactId>xml-maven-plugin</artifactId>
                <inherited>false</inherited>
                <executions>
                    <execution>
                        <!-- Cleanup the effective POM -->
                        <id>post-process-effective-pom</id>
                        <phase>process-resources</phase>
                        <goals>
                            <goal>transform</goal>
                        </goals>
                        <configuration>
                            <transformationSets>
                                <transformationSet>
                                    <dir>${project.build.directory}/effective-pom</dir>
                                    <outputDir>${project.build.directory}/effective-pom</outputDir>
                                    <stylesheet>src/main/xslt/post-process-flattened-pom.xsl</stylesheet>
                                    <outputProperties>
                                        <outputProperty>
                                            <name>indent</name>
                                            <value>yes</value>
                                        </outputProperty>
                                    </outputProperties>
                                </transformationSet>
                            </transformationSets>
                        </configuration>
                    </execution>
                    <execution>
                        <!-- Cleanup the flattened project POM -->
                        <id>post-process-flattened-pom</id>
                        <phase>process-resources</phase>
                        <goals>
                            <goal>transform</goal>
                        </goals>
                        <configuration>
                            <transformationSets>
                                <transformationSet>
                                    <dir>${project.basedir}</dir>
                                    <outputDir>${project.basedir}</outputDir>
                                    <includes>.flattened-pom.xml</includes>
                                    <stylesheet>src/main/xslt/post-process-flattened-pom.xsl</stylesheet>
                                    <outputProperties>
                                        <outputProperty>
                                            <name>indent</name>
                                            <value>yes</value>
                                        </outputProperty>
                                    </outputProperties>
                                </transformationSet>
                            </transformationSets>
                        </configuration>
                    </execution>
                </executions>
            </plugin>
            <plugin>
                <groupId>org.codehaus.mojo</groupId>
                <artifactId>build-helper-maven-plugin</artifactId>
                <inherited>false</inherited>
                <executions>
                    <execution>
                        <!-- Attach effective POM -->
                        <id>attach-artifacts</id>
                        <phase>package</phase>
                        <goals>
                            <goal>attach-artifact</goal>
                        </goals>
                        <configuration>
                            <artifacts>
                                <artifact>
                                    <file>${project.build.directory}/effective-pom/continew-starter-dependencies.xml</file>
                                    <type>effective-pom</type>
                                </artifact>
                            </artifacts>
                        </configuration>
                    </execution>
                </executions>
            </plugin>
        </plugins>
    </build>

    <profiles>
        <profile>
            <id>release</id>
            <build>
                <plugins>
                    <plugin>
                        <groupId>org.apache.maven.plugins</groupId>
                        <artifactId>maven-source-plugin</artifactId>
                        <executions>
                            <execution>
                                <phase>package</phase>
                                <goals>
                                    <goal>jar-no-fork</goal>
                                </goals>
                            </execution>
                        </executions>
                    </plugin>
                    <plugin>
                        <groupId>org.apache.maven.plugins</groupId>
                        <artifactId>maven-javadoc-plugin</artifactId>
                        <executions>
                            <execution>
                                <phase>package</phase>
                                <goals>
                                    <goal>jar</goal>
                                </goals>
                            </execution>
                        </executions>
                    </plugin>
                    <plugin>
                        <groupId>org.apache.maven.plugins</groupId>
                        <artifactId>maven-gpg-plugin</artifactId>
                        <version>3.1.0</version>
                        <executions>
                            <execution>
                                <phase>verify</phase>
                                <goals>
                                    <goal>sign</goal>
                                </goals>
                            </execution>
                        </executions>
                    </plugin>
                </plugins>
            </build>
            <distributionManagement>
                <snapshotRepository>
                    <id>sonatype-nexus-snapshots</id>
                    <name>Sonatype Nexus Snapshots</name>
                    <url>https://s01.oss.sonatype.org/content/repositories/snapshots/</url>
                </snapshotRepository>
                <repository>
                    <id>sonatype-nexus-staging</id>
                    <name>Nexus Release Repository</name>
                    <url>https://s01.oss.sonatype.org/service/local/staging/deploy/maven2/</url>
                </repository>
            </distributionManagement>
        </profile>
    </profiles>
</project>