<?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>

    <groupId>cloud.opencode.base</groupId>
    <artifactId>opencode-base-code</artifactId>
    <version>2.0.3</version>

    <name>${project.artifactId}</name>
    <url>https://github.com/opencodecloud/opencode-base-code</url>
    <description>opencode-base-code is a standard result and exception information.</description>

    <licenses>
        <license>
            <name>Apache License, Version 2.0</name>
            <url>http://www.apache.org/licenses/LICENSE-2.0.txt</url>
            <distribution>repo</distribution>
        </license>
    </licenses>

    <scm>
        <url>https://github.com/opencodecloud/opencode-base-code</url>
        <connection>scm:git:https://github.com/opencodecloud/opencode-base-code.git</connection>
        <developerConnection>scm:git:https://github.com/opencodecloud/opencode-base-code.git</developerConnection>
        <tag>HEAD</tag>
    </scm>

    <properties>
        <maven.compiler.source>17</maven.compiler.source>
        <maven.compiler.target>17</maven.compiler.target>
        <maven.deploy.skip>true</maven.deploy.skip>
        <project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
        <project.reporting.outputEncoding>UTF-8</project.reporting.outputEncoding>
        <maven.compiler.encoding>UTF-8</maven.compiler.encoding>
        <maven.test.skip>true</maven.test.skip>
        <spring-boot.version>3.2.1</spring-boot.version>
        <lombok.version>1.18.30</lombok.version>
        <httpmime.version>4.5.14</httpmime.version>
        <commons-lang3.version>3.13.0</commons-lang3.version>
    </properties>

    <developers>
        <developer>
            <name>Jon</name>
            <email>ijonso123@gmail.com</email>
            <url>https://jon.wiki</url>
            <organization>opencode.cloud</organization>
            <organizationUrl>https://opencode.cloud</organizationUrl>
            <roles>
                <role>Architect</role>
                <role>Developer</role>
            </roles>
            <timezone>+8</timezone>
        </developer>
    </developers>

    <dependencyManagement>
        <dependencies>
            <dependency>
                <groupId>org.springframework.boot</groupId>
                <artifactId>spring-boot-dependencies</artifactId>
                <version>${spring-boot.version}</version>
                <type>pom</type>
                <scope>import</scope>
            </dependency>
        </dependencies>
    </dependencyManagement>

    <dependencies>
        <dependency>
            <groupId>org.projectlombok</groupId>
            <artifactId>lombok</artifactId>
            <version>${lombok.version}</version>
            <scope>compile</scope>
        </dependency>
        <dependency>
            <groupId>org.springframework.boot</groupId>
            <artifactId>spring-boot-starter-web</artifactId>
            <scope>provided</scope>
        </dependency>
        <dependency>
            <groupId>org.apache.httpcomponents</groupId>
            <artifactId>httpmime</artifactId>
            <version>${httpmime.version}</version>
        </dependency>
        <dependency>
            <groupId>org.apache.commons</groupId>
            <artifactId>commons-lang3</artifactId>
            <version>${commons-lang3.version}</version>
        </dependency>
    </dependencies>



    <profiles>
        <profile>
            <id>release</id>
            <activation>
                <activeByDefault>true</activeByDefault>
            </activation>
            <build>
                <plugins>
<!--                    <plugin>-->
<!--                        <groupId>org.sonatype.plugins</groupId>-->
<!--                        <artifactId>nexus-staging-maven-plugin</artifactId>-->
<!--                        <version>1.7.0</version>-->
<!--                        <extensions>true</extensions>-->
<!--                        <executions>-->
<!--                            <execution>-->
<!--                                <id>default-deploy</id>-->
<!--                                <phase>deploy</phase>-->
<!--                                <goals>-->
<!--                                    <goal>deploy</goal>-->
<!--                                </goals>-->
<!--                            </execution>-->
<!--                        </executions>-->
<!--                        <configuration>-->
<!--                            <serverId>ossrh</serverId>-->
<!--                            <nexusUrl>https://s01.oss.sonatype.org/</nexusUrl>-->
<!--                            <autoReleaseAfterClose>true</autoReleaseAfterClose>-->
<!--                        </configuration>-->
<!--                    </plugin>-->
                    <plugin>
                        <groupId>org.sonatype.central</groupId>
                        <artifactId>central-publishing-maven-plugin</artifactId>
                        <version>0.7.0</version>
                        <extensions>true</extensions>
                        <configuration>
                            <publishingServerId>ossrh</publishingServerId>
                        </configuration>
                    </plugin>
                    <plugin>
                        <groupId>org.apache.maven.plugins</groupId>
                        <artifactId>maven-compiler-plugin</artifactId>
                        <version>3.14.0</version>
                        <configuration>
                            <source>17</source>
                            <target>17</target>
                        </configuration>
                    </plugin>
                    <plugin>
                        <groupId>org.apache.maven.plugins</groupId>
                        <artifactId>maven-source-plugin</artifactId>
                        <version>3.3.1</version>
                        <executions>
                            <execution>
                                <id>attach-sources</id>
                                <phase>verify</phase>
                                <goals>
                                    <goal>jar-no-fork</goal>
                                </goals>
                            </execution>
                        </executions>
                    </plugin>
                    <plugin>
                        <groupId>org.apache.maven.plugins</groupId>
                        <artifactId>maven-javadoc-plugin</artifactId>
                        <version>3.11.2</version>
                        <configuration>
                            <show>private</show>
                            <nohelp>true</nohelp>
                            <charset>UTF-8</charset>
                            <encoding>UTF-8</encoding>
                            <docencoding>UTF-8</docencoding>
                            <additionalJOption>-Xdoclint:none</additionalJOption>
                        </configuration>
                        <executions>
                            <execution>
                                <id>attach-javadocs</id>
                                <phase>verify</phase>
                                <goals>
                                    <goal>jar</goal>
                                </goals>
                            </execution>
                        </executions>
                    </plugin>
                    <plugin>
                        <groupId>org.apache.maven.plugins</groupId>
                        <artifactId>maven-gpg-plugin</artifactId>
                        <version>3.2.7</version>
                        <configuration>
<!--                             指定密钥名称（可选） -->
                            <keyname>E612F837CE1DA65A3460933BD0A30722B30D351B</keyname>
<!--                             从 settings.xml 或命令行读取密码 -->
                            <passphrase>${gpg.passphrase}</passphrase>
<!--                             启用批处理模式（避免交互式输入） -->
                            <gpgArguments>
                                <arg>--batch</arg>
                                <arg>--pinentry-mode</arg>
                                <arg>loopback</arg>
                            </gpgArguments>
                        </configuration>
                        <executions>
                            <execution>
                                <id>sign-artifacts</id>
                                <phase>verify</phase>
                                <goals>
                                    <goal>sign</goal>
                                </goals>
                            </execution>
                        </executions>
                    </plugin>
                </plugins>
            </build>
            <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>
        </profile>
    </profiles>

</project>