<?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 https://maven.apache.org/xsd/maven-4.0.0.xsd">
    <modelVersion>4.0.0</modelVersion>

    <packaging>pom</packaging>

    <groupId>com.neko233</groupId>
    <artifactId>neko233-skilltree</artifactId>
    <version>0.0.2</version>


    <name>neko233-toolchain-all</name>
    <url>https://github.com/SolarisNeko/neko233-toolchain-all/tree/main</url>

    <modules>
        <!-- All -->
        <module>skilltree-all</module>

        <!-- 通用层 -->
        <module>skilltree-commons-core</module>
        <module>skilltree-commons-sql</module>
        <module>skilltree-commons-api</module>
        <module>skilltree-commons-parser</module>
        <module>skilltree-commons-metrics</module>
        <module>skilltree-commons-reactive</module>
        <module>skilltree-commons-event-system</module>
        <module>skilltree-commons-storage</module>

        <!-- 功能层 -->
        <module>skilltree-aop</module>
        <module>skilltree-actor</module>
        <module>skilltree-counter</module>
        <module>skilltree-id-generator</module>
        <module>skilltree-i18n</module>
        <module>skilltree-distribute-system</module>
        <module>skilltree-memory-database</module>
        <module>skilltree-validator</module>
    </modules>

    <description>
        neko233-toolchain-all is a tool box~
        工具盒子~

    </description>

    <developers>
        <developer>
            <name>SolarisNeko</name>
            <url>https://github.com/SolarisNeko</url>
        </developer>
    </developers>

    <scm>
        <connection>scm:git:https://github.com/SolarisNeko/neko233-toolchain-all.git</connection>
        <developerConnection>scm:git:ssh://github.com/SolarisNeko/neko233-toolchain-all.git</developerConnection>
        <url>http://github.com/SolarisNeko/neko233-toolchain-all/tree/main</url>
    </scm>

    <licenses>
        <license>
            <name>Apache 2.0</name>
            <url>https://www.apache.org/licenses/LICENSE-2.0.txt</url>
        </license>
    </licenses>

    <properties>
        <compile.version>8</compile.version>
        <java.version>8</java.version>
        <maven.compiler.source>8</maven.compiler.source>
        <github.global.server>github</github.global.server>

        <project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
        <project.reporting.outputEncoding>UTF-8</project.reporting.outputEncoding>

        <gpg.executable>gpg</gpg.executable>

<!--        <Automatic-Module-Name>com.neko233</Automatic-Module-Name>-->

        <!-- plugin -->
        <lombok.version>1.18.24</lombok.version>
        <!-- Log -->
        <slf4j-api.version>1.7.36</slf4j-api.version>
    </properties>

    <dependencies>

        <!-- Serialize -->
        <dependency>
            <groupId>com.alibaba.fastjson2</groupId>
            <artifactId>fastjson2</artifactId>
            <version>2.0.20</version>
        </dependency>


        <!-- Log Facade -->
        <dependency>
            <groupId>org.slf4j</groupId>
            <artifactId>slf4j-api</artifactId>
            <version>${slf4j-api.version}</version>
            <scope>compile</scope>
        </dependency>
        <!-- not provide, just use to test -->
        <dependency>
            <groupId>ch.qos.logback</groupId>
            <artifactId>logback-classic</artifactId>
            <version>1.2.11</version>
            <scope>test</scope>
        </dependency>


        <dependency>
            <groupId>org.projectlombok</groupId>
            <artifactId>lombok</artifactId>
            <version>${lombok.version}</version>
            <!--            <scope>compile</scope>-->
            <!--            <optional>true</optional>-->
        </dependency>


        <!-- Apache | 比较通用, 还是保留了 -->
        <dependency>
            <groupId>org.apache.commons</groupId>
            <artifactId>commons-lang3</artifactId>
            <version>3.12.0</version>
        </dependency>
        <dependency>
            <groupId>org.apache.commons</groupId>
            <artifactId>commons-collections4</artifactId>
            <version>4.4</version>
        </dependency>

        <!-- IO -->
        <dependency>
            <groupId>commons-io</groupId>
            <artifactId>commons-io</artifactId>
            <version>2.11.0</version>
        </dependency>


        <!--Test-->
        <dependency>
            <groupId>junit</groupId>
            <artifactId>junit</artifactId>
            <version>4.13.1</version>
            <scope>test</scope>
        </dependency>

        <!-- Post Processor -->

    </dependencies>

    <distributionManagement>
        <snapshotRepository>
            <id>ossrh</id>
            <url>https://s01.oss.sonatype.org/content/repositories/snapshots</url>
        </snapshotRepository>
        <repository>
            <id>ossrh</id>
            <url>https://s01.oss.sonatype.org/service/local/staging/deploy/maven2/</url>
        </repository>
    </distributionManagement>

    <!--    <profiles>-->
    <!--        <profile>-->
    <!--            <id>java8-doclint-disabled</id>-->
    <!--            <activation>-->
    <!--                <jdk>[1.8,)</jdk>-->
    <!--            </activation>-->
    <!--            <properties>-->
    <!--                <javadoc.opts>-Xdoclint:none</javadoc.opts>-->
    <!--            </properties>-->
    <!--        </profile>-->
    <!--    </profiles>-->


    <build>
        <plugins>
            <!-- Lombok -->
            <plugin>
                <groupId>org.projectlombok</groupId>
                <artifactId>lombok</artifactId>
                <version>${lombok.version}</version>
            </plugin>
            <plugin>
                <groupId>org.apache.maven.plugins</groupId>
                <artifactId>maven-compiler-plugin</artifactId>
                <version>3.8.1</version>
                <configuration>
                    <encoding>UTF-8</encoding>
                    <source>8</source>
                    <target>8</target>
                </configuration>
            </plugin>
            <plugin>
                <groupId>org.apache.maven.plugins</groupId>
                <artifactId>maven-source-plugin</artifactId>
                <version>3.1.0</version>
                <executions>
                    <execution>
                        <id>attach-sources</id>
                        <goals>
                            <goal>jar-no-fork</goal>
                        </goals>
                    </execution>
                </executions>
            </plugin>
            <plugin>
                <groupId>org.apache.maven.plugins</groupId>
                <artifactId>maven-jar-plugin</artifactId>
                <version>3.3.0</version>
                <configuration>
                    <archive>
                        <index>true</index>
                        <manifest>
                            <addDefaultImplementationEntries>true</addDefaultImplementationEntries>
                        </manifest>
                        <manifestEntries>
                            <Build-OS>${os.name}</Build-OS>
                            <Built-By>${user.name}</Built-By>
                            <Build-Jdk>${java.version}</Build-Jdk>
                            <Build-Timestamp>${maven.build.timestamp}</Build-Timestamp>
<!--                            <Automatic-Module-Name>${Automatic-Module-Name}</Automatic-Module-Name>-->
                        </manifestEntries>
                    </archive>
                </configuration>
            </plugin>
            <!-- Javadoc -->
            <plugin>
                <groupId>org.apache.maven.plugins</groupId>
                <artifactId>maven-javadoc-plugin</artifactId>
                <version>3.5.0</version>
                <executions>
                    <execution>
                        <!--                        <phase>package</phase>-->
                        <id>attach-javadocs</id>
                        <goals>
                            <goal>jar</goal>
                        </goals>
                        <configuration>
                            <additionalJOption>-Xdoclint:none</additionalJOption>
                        </configuration>
                    </execution>

                </executions>
            </plugin>
        </plugins>
    </build>

    <profiles>
        <profile>
            <id>release</id>
            <distributionManagement>
                <snapshotRepository>
                    <id>ossrh</id>
                    <url>https://s01.oss.sonatype.org/content/repositories/snapshots</url>
                </snapshotRepository>
                <repository>
                    <id>ossrh</id>
                    <url>https://s01.oss.sonatype.org/service/local/staging/deploy/maven2/</url>
                </repository>
            </distributionManagement>
            <build>
                <plugins>
                    <!-- Source -->
                    <plugin>
                        <groupId>org.apache.maven.plugins</groupId>
                        <artifactId>maven-source-plugin</artifactId>
                        <version>3.2.1</version>
                        <executions>
                            <execution>
                                <id>ossrh</id>
                                <phase>package</phase>
                                <goals>
                                    <goal>jar-no-fork</goal>
                                </goals>
                            </execution>
                        </executions>
                    </plugin>
                    <!-- 测试覆盖度 -->
                    <plugin>
                        <groupId>org.codehaus.mojo</groupId>
                        <artifactId>cobertura-maven-plugin</artifactId>
                        <version>2.7</version>
                        <configuration>
                            <formats>
                                <format>html</format>
                                <format>xml</format>
                            </formats>
                            <check/>
                        </configuration>
                    </plugin>
                    <!-- Gpg Signature -->
                    <plugin>
                        <groupId>org.apache.maven.plugins</groupId>
                        <artifactId>maven-gpg-plugin</artifactId>
                        <version>1.6</version>
                        <executions>
                            <execution>
<!--                                <id>ossrh</id>-->
                                <id>sign-artifacts</id>
                                <phase>verify</phase>
                                <goals>
                                    <goal>sign</goal>
                                </goals>
                            </execution>
                        </executions>
                    </plugin>

                    <plugin>
                        <groupId>org.sonatype.plugins</groupId>
                        <artifactId>nexus-staging-maven-plugin</artifactId>
                        <version>1.6.3</version>
                        <extensions>true</extensions>
                        <configuration>
                            <serverId>ossrh</serverId>
                            <nexusUrl>https://s01.oss.sonatype.org/</nexusUrl>
                            <autoReleaseAfterClose>true</autoReleaseAfterClose>
                        </configuration>
                    </plugin>

                </plugins>
            </build>
        </profile>
    </profiles>

</project>