<?xml version="1.0" encoding="UTF-8"?>
<!--
~   Licensed under the Apache License, Version 2.0 (the "License");
~   you may not use this file except in compliance with the License.
~   You may obtain a copy of the License at
~
~   http://www.apache.org/licenses/LICENSE-2.0
~
~   Unless required by applicable law or agreed to in writing, software
~   distributed under the License is distributed on an "AS IS" BASIS,
~   WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
~   See the License for the specific language governing permissions and
~   limitations under the License.
-->
<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>

    <parent>
        <groupId>org.jdbi</groupId>
        <artifactId>jdbi3-build-parent</artifactId>
        <version>3.44.1</version>
    </parent>

    <groupId>org.jdbi</groupId>
    <artifactId>jdbi3-guava-cache</artifactId>
    <version>3.44.1</version>

    <name>jdbi3 guava cache</name>
    <description>Cache implementation with the guava cache</description>

    <scm>
        <connection>scm:git:git://github.com/jdbi/jdbi3-guava-cache.git</connection>
        <developerConnection>scm:git:git@github.com:jdbi/jdbi3-guava-cache.git</developerConnection>
        <tag>v3.44.1</tag>
        <url>https://github.com/jdbi/jdbi3-guava-cache/</url>
    </scm>

    <properties>
        <!-- run with -Dbasepom.it.skip=false to run tests using the guava cache plugin -->
        <basepom.it.skip>true</basepom.it.skip>

        <!-- site requires full javadoc generation -->
        <basepom.javadoc.skip>false</basepom.javadoc.skip>

        <basepom.site.scm.branch>master</basepom.site.scm.branch>
        <basepom.site.scm.checkout-directory>${java.io.tmpdir}/gh-pages-publish/${project.artifactId}</basepom.site.scm.checkout-directory>
        <basepom.site.scm.id>github</basepom.site.scm.id>
        <basepom.site.scm.site-path>modules/${project.artifactId}</basepom.site.scm.site-path>
        <basepom.site.scm.skip-deploy>false</basepom.site.scm.skip-deploy>
        <basepom.site.scm.url>scm:git:https://github.com/jdbi/jdbi.github.io</basepom.site.scm.url>

        <basepom.site.skip>false</basepom.site.skip>

        <!-- base version to build against. Must be released before this module can be released. -->
        <dep.jdbi3.version>${project.parent.version}</dep.jdbi3.version>

        <moduleName>org.jdbi.v3.cache.guava</moduleName>
    </properties>

    <dependencyManagement>
        <dependencies>
            <dependency>
                <groupId>org.jdbi</groupId>
                <artifactId>jdbi3-bom</artifactId>
                <version>${dep.jdbi3.version}</version>
                <type>pom</type>
                <scope>import</scope>
            </dependency>
        </dependencies>
    </dependencyManagement>

    <dependencies>
        <dependency>
            <groupId>org.jdbi</groupId>
            <artifactId>jdbi3-core</artifactId>
        </dependency>

        <dependency>
            <groupId>com.google.guava</groupId>
            <artifactId>guava</artifactId>
        </dependency>

        <dependency>
            <groupId>org.jdbi</groupId>
            <artifactId>jdbi3-core</artifactId>
            <classifier>tests</classifier>
            <scope>test</scope>
        </dependency>

        <dependency>
            <groupId>org.jdbi</groupId>
            <artifactId>jdbi3-testing</artifactId>
            <scope>test</scope>
        </dependency>

        <dependency>
            <groupId>com.h2database</groupId>
            <artifactId>h2</artifactId>
            <scope>test</scope>
        </dependency>
    </dependencies>

    <!-- repos are required to access the snapshot deps from the main build -->
    <repositories>
        <repository>
            <releases>
                <enabled>false</enabled>
            </releases>
            <snapshots>
                <enabled>true</enabled>
                <updatePolicy>always</updatePolicy>
                <checksumPolicy>fail</checksumPolicy>
            </snapshots>
            <id>snapshots-repo</id>
            <name>Nexus Snapshots</name>
            <url>https://oss.sonatype.org/content/repositories/snapshots</url>
            <layout>default</layout>
        </repository>
    </repositories>
    <pluginRepositories>
        <pluginRepository>
            <releases>
                <enabled>false</enabled>
            </releases>
            <snapshots>
                <enabled>true</enabled>
                <updatePolicy>always</updatePolicy>
                <checksumPolicy>fail</checksumPolicy>
            </snapshots>
            <id>snapshots-repo</id>
            <name>Nexus Snapshots</name>
            <url>https://oss.sonatype.org/content/repositories/snapshots</url>
            <layout>default</layout>
        </pluginRepository>
    </pluginRepositories>

    <build>
        <pluginManagement>
            <plugins>
                <plugin>
                    <groupId>org.apache.maven.plugins</groupId>
                    <artifactId>maven-javadoc-plugin</artifactId>
                    <configuration>
                        <links combine.children="append">
                            <link>https://jdbi.org/releases/${dep.jdbi3.version}/apidocs</link>
                        </links>
                    </configuration>
                </plugin>
                <plugin>
                    <groupId>org.apache.maven.plugins</groupId>
                    <artifactId>maven-scm-publish-plugin</artifactId>
                    <configuration>
                        <ignorePathsToDelete combine.children="append">
                            <!-- don't touch the release folders -->
                            <ignorePathToDelete>releases</ignorePathToDelete>
                        </ignorePathsToDelete>
                    </configuration>
                </plugin>
            </plugins>
        </pluginManagement>
        <plugins>
            <plugin>
                <groupId>org.apache.maven.plugins</groupId>
                <artifactId>maven-invoker-plugin</artifactId>
            </plugin>
        </plugins>
    </build>

    <profiles>
        <profile>
            <id>jdbi-release</id>
            <properties>
                <basepom.site.scm.site-path>modules/${project.artifactId}/releases/${project.version}</basepom.site.scm.site-path>
            </properties>
        </profile>
    </profiles>
</project>
