<?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>com.github.pagehelper</groupId>
    <artifactId>pagehelper-sqlparser</artifactId>
    <version>6.1.0</version>
    <packaging>pom</packaging>
    <modules>
        <module>sqlparser4.5</module>
        <module>sqlparser4.7</module>
        <module>sqlparser-timeout</module>
    </modules>

    <properties>
        <maven.compiler.source>8</maven.compiler.source>
        <maven.compiler.target>8</maven.compiler.target>
        <project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
    </properties>

    <name>pagehelper-sqlparser</name>
    <description>Mybatis Pagination Plugin SqlParser Extend</description>
    <url>https://github.com/pagehelper/pagehelper-sqlparser</url>

    <licenses>
        <license>
            <name>The MIT License (MIT)</name>
            <url>https://github.com/pagehelper/pagehelper-sqlparser/blob/master/LICENSE</url>
        </license>
    </licenses>

    <developers>
        <developer>
            <name>rui</name>
            <email>rui0310@126.com</email>
        </developer>
    </developers>

    <scm>
        <connection>scm:git:git@github.com:pagehelper/pagehelper-sqlparser.git</connection>
        <developerConnection>scm:git:git@github.com:pagehelper/pagehelper-sqlparser.git</developerConnection>
        <url>git@github.com:pagehelper/pagehelper-sqlparser.git</url>
    </scm>

    <dependencyManagement>
        <dependencies>
            <dependency>
                <groupId>com.github.pagehelper</groupId>
                <artifactId>pagehelper</artifactId>
                <version>6.1.0</version>
                <scope>compile</scope>
                <optional>true</optional>
            </dependency>

            <dependency>
                <groupId>org.mybatis</groupId>
                <artifactId>mybatis</artifactId>
                <version>3.5.10</version>
                <scope>compile</scope>
                <optional>true</optional>
            </dependency>

            <dependency>
                <groupId>junit</groupId>
                <artifactId>junit</artifactId>
                <version>4.13.2</version>
                <scope>test</scope>
            </dependency>
        </dependencies>
    </dependencyManagement>

    <profiles>
        <profile>
            <id>release</id>
            <build>
                <plugins>
                    <!--Compiler-->
                    <plugin>
                        <artifactId>maven-compiler-plugin</artifactId>
                    </plugin>
                    <!-- Source -->
                    <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>
                    <!-- Javadoc -->
                    <plugin>
                        <groupId>org.apache.maven.plugins</groupId>
                        <artifactId>maven-javadoc-plugin</artifactId>
                        <version>3.2.0</version>
                        <configuration>
                            <additionalOptions>
                                <additionalOption>-Xdoclint:none</additionalOption>
                            </additionalOptions>
                        </configuration>
                        <executions>
                            <execution>
                                <phase>package</phase>
                                <goals>
                                    <goal>jar</goal>
                                </goals>
                            </execution>
                        </executions>
                    </plugin>
                    <!-- GPG mvn clean deploy -P release -Dgpg.passphrase=YourPassphase-->
                    <plugin>
                        <groupId>org.apache.maven.plugins</groupId>
                        <artifactId>maven-gpg-plugin</artifactId>
                        <executions>
                            <execution>
                                <id>sign-artifacts</id>
                                <phase>verify</phase>
                                <goals>
                                    <goal>sign</goal>
                                </goals>
                            </execution>
                        </executions>
                        <configuration>
                            <gpgArguments>
                                <argument>--pinentry-mode</argument>
                                <argument>loopback</argument>
                            </gpgArguments>
                        </configuration>
                    </plugin>
                    <plugin>
                        <groupId>org.sonatype.plugins</groupId>
                        <artifactId>nexus-staging-maven-plugin</artifactId>
                        <extensions>true</extensions>
                        <configuration>
                            <serverId>ossrh</serverId>
                            <nexusUrl>https://oss.sonatype.org/</nexusUrl>
                            <autoReleaseAfterClose>true</autoReleaseAfterClose>
                        </configuration>
                    </plugin>
                </plugins>
            </build>
            <distributionManagement>
                <snapshotRepository>
                    <id>ossrh</id>
                    <url>https://oss.sonatype.org/content/repositories/snapshots/</url>
                </snapshotRepository>
                <repository>
                    <id>ossrh</id>
                    <url>https://oss.sonatype.org/service/local/staging/deploy/maven2/</url>
                </repository>
            </distributionManagement>
        </profile>
    </profiles>
</project>