<?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.sonatype.oss</groupId>
    <artifactId>oss-parent</artifactId>
    <version>9</version>
  </parent>

  <groupId>org.pac4j</groupId>
  <artifactId>dropwizard-pac4j</artifactId>
  <packaging>jar</packaging>
  <version>3.0.0</version>
  <name>Dropwizard pac4j Support</name>
  <description>Dropwizard bundle adding support for the pac4j security engine</description>
  <url>https://github.com/pac4j/dropwizard-pac4j</url>

  <repositories>
    <repository>
      <id>sonatype-nexus-snapshots</id>
      <name>Sonatype Nexus Snapshots</name>
      <url>https://oss.sonatype.org/content/repositories/snapshots</url>
      <releases>
        <enabled>false</enabled>
      </releases>
      <snapshots>
        <enabled>true</enabled>
      </snapshots>
    </repository>
    <repository>
      <id>sonatype-nexus</id>
      <name>Sonatype Nexus</name>
      <url>https://oss.sonatype.org/content/repositories/releases</url>
      <releases>
        <enabled>true</enabled>
      </releases>
      <snapshots>
        <enabled>false</enabled>
      </snapshots>
    </repository>
  </repositories>

  <licenses>
    <license>
      <name>The Apache Software License, Version 2.0</name>
      <url>http://www.apache.org/licenses/LICENSE-2.0.txt</url>
      <distribution>repo</distribution>
    </license>
  </licenses>

  <organization>
    <name>pac4j</name>
    <url>http://www.pac4j.org/</url>
  </organization>

  <developers>
    <developer>
      <id>victornoel</id>
      <name>Victor NOEL</name>
      <url>https://github.com/victornoel</url>
    </developer>
    <developer>
      <id>evanm</id>
      <name>Evan Meagher</name>
      <email>evan.meagher@gmail.com</email>
      <organization>Dropwizard</organization>
      <organizationUrl>http://www.dropwizard.io</organizationUrl>
    </developer>
  </developers>

  <scm>
    <url>https://github.com/pac4j/dropwizard-pac4j.git</url>
    <connection>https://github.com/pac4j/dropwizard-pac4j.git</connection>
    <developerConnection>scm:git:git@github.com:pac4j/dropwizard-pac4j.git</developerConnection>
  </scm>

  <issueManagement>
    <system>GitHub Issues</system>
    <url>https://github.com/pac4j/dropwizard-pac4j/issues</url>
  </issueManagement>

  <properties>
    <project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
    <project.reporting.outputEncoding>UTF-8</project.reporting.outputEncoding>
    <maven.compiler.source>1.8</maven.compiler.source>
    <maven.compiler.target>1.8</maven.compiler.target>
    <dropwizard.version>1.3.0</dropwizard.version>
    <pac4j.version>3.0.0</pac4j.version>
    <jax-rs-pac4j.version>3.0.0</jax-rs-pac4j.version>
    <j2e-pac4j.version>4.0.0</j2e-pac4j.version>
  </properties>

  <dependencyManagement>
    <dependencies>
      <dependency>
        <groupId>io.dropwizard</groupId>
        <artifactId>dropwizard-bom</artifactId>
        <version>${dropwizard.version}</version>
        <type>pom</type>
        <scope>import</scope>
      </dependency>
    </dependencies>
  </dependencyManagement>

  <dependencies>
    <dependency>
      <groupId>io.dropwizard</groupId>
      <artifactId>dropwizard-core</artifactId>
      <scope>provided</scope>
    </dependency>
    <dependency>
      <groupId>org.pac4j</groupId>
      <artifactId>pac4j-core</artifactId>
      <version>${pac4j.version}</version>
    </dependency>
    <dependency>
      <groupId>org.pac4j</groupId>
      <artifactId>pac4j-config</artifactId>
      <version>${pac4j.version}</version>
    </dependency>
    <dependency>
      <groupId>org.pac4j</groupId>
      <artifactId>jersey225-pac4j</artifactId>
      <version>${jax-rs-pac4j.version}</version>
    </dependency>
    <dependency>
      <groupId>org.pac4j</groupId>
      <artifactId>j2e-pac4j</artifactId>
      <version>${j2e-pac4j.version}</version>
    </dependency>
    <dependency>
      <groupId>org.pac4j</groupId>
      <artifactId>pac4j-http</artifactId>
      <version>${pac4j.version}</version>
      <scope>test</scope>
    </dependency>
    <dependency>
      <groupId>org.pac4j</groupId>
      <artifactId>pac4j-oauth</artifactId>
      <version>${pac4j.version}</version>
      <scope>test</scope>
    </dependency>
    <dependency>
      <groupId>io.dropwizard</groupId>
      <artifactId>dropwizard-testing</artifactId>
      <scope>test</scope>
    </dependency>
    <dependency>
      <groupId>org.mockito</groupId>
      <artifactId>mockito-core</artifactId>
      <scope>test</scope>
    </dependency>
  </dependencies>

  <build>
    <plugins>
      <plugin>
        <groupId>org.apache.maven.plugins</groupId>
        <artifactId>maven-compiler-plugin</artifactId>
        <version>3.5.1</version>
      </plugin>
      <plugin>
        <groupId>org.apache.maven.plugins</groupId>
        <artifactId>maven-source-plugin</artifactId>
        <version>3.0.1</version>
      </plugin>
      <plugin>
        <groupId>org.apache.maven.plugins</groupId>
        <artifactId>maven-javadoc-plugin</artifactId>
        <version>2.10.4</version>
      </plugin>
      <plugin>
        <groupId>org.codehaus.mojo</groupId>
        <artifactId>findbugs-maven-plugin</artifactId>
        <version>3.0.5</version>
        <configuration>
          <effort>Low</effort>
          <threshold>Max</threshold>
          <failOnError>true</failOnError>
          <includeTests>true</includeTests>
        </configuration>
        <executions>
          <execution>
            <id>run-findbugs</id>
            <phase>compile</phase>
            <goals>
              <goal>check</goal>
            </goals>
          </execution>
        </executions>
      </plugin>
      <plugin>
        <groupId>org.apache.maven.plugins</groupId>
        <artifactId>maven-pmd-plugin</artifactId>
        <version>3.9.0</version>
        <configuration>
          <includeTests>true</includeTests>
          <printFailingErrors>true</printFailingErrors>
        </configuration>
        <executions>
          <execution>
            <id>run-pmd</id>
            <phase>compile</phase>
            <goals>
              <goal>check</goal>
            </goals>
          </execution>
        </executions>
      </plugin>
      <plugin>
        <groupId>org.apache.maven.plugins</groupId>
        <artifactId>maven-enforcer-plugin</artifactId>
        <version>3.0.0-M1</version>
        <executions>
          <execution>
            <id>dependency-convergence</id>
            <configuration>
              <rules>
                <dependencyConvergence />
              </rules>
            </configuration>
            <goals>
              <goal>enforce</goal>
            </goals>
          </execution>
        </executions>
      </plugin>
    </plugins>
  </build>

  <profiles>
    <profile>
      <id>release-sign-artifacts</id>
      <activation>
        <property>
          <name>performRelease</name>
          <value>true</value>
        </property>
      </activation>
      <build>
        <plugins>
          <plugin>
            <groupId>org.apache.maven.plugins</groupId>
            <artifactId>maven-gpg-plugin</artifactId>
            <version>1.6</version>
            <executions>
              <execution>
                <id>sign-artifacts</id>
                <phase>verify</phase>
                <goals>
                  <goal>sign</goal>
                </goals>
              </execution>
            </executions>
          </plugin>
        </plugins>
      </build>
    </profile>
  </profiles>

</project>
