<!-- 
  Copyright (c) 2017 Georgi Pavlov (georgi.pavlov@isoft-technology.com).
  All rights reserved. This program and the accompanying materials
  are made available under the terms of the MIT license which accompanies 
  this distribution, and is available at 
  https://github.com/tengia/oauth-2/blob/master/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 http://maven.apache.org/xsd/maven-4.0.0.xsd">
	<modelVersion>4.0.0</modelVersion>

	<artifactId>oauth2-parent</artifactId>
	<packaging>pom</packaging>

	<name>${project.groupId}:${project.artifactId}</name>
	<url>https://github.com/tengia/oauth-2</url>
	<inceptionYear>2017</inceptionYear>

	<parent>
		<groupId>net.oauth-2</groupId>
		<artifactId>oauth2-client-bom</artifactId>
		<version>1.1.0</version>
		<relativePath>../oauth2-client-bom/pom.xml</relativePath>
	</parent>

	<licenses>
		<license>
			<name>MIT License</name>
			<url>http://www.opensource.org/licenses/mit-license.php</url>
		</license>
	</licenses>

	<developers>
		<developer>
			<name>tengia</name>
			<url>https://github.com/tengia</url>
		</developer>
	</developers>

	<scm>
		<url>https://github.com/tengia/oauth-2</url>
		<connection>scm:git:git@github.com:tengia/oauth-2.git</connection>
		<developerConnection>scm:git:git@github.com:tengia/oauth-2.git</developerConnection>
		<tag>v1.1.0</tag>
	</scm>

	<issueManagement>
		<url>https://github.com/tengia/oauth-2/issues</url>
	</issueManagement>

	<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>

	<properties>
		<java.version>1.8</java.version>
		<encoding>UTF-8</encoding>
		<project.build.sourceEncoding>${encoding}</project.build.sourceEncoding>
		<project.reporting.outputEncoding>${encoding}</project.reporting.outputEncoding>
		<maven.compiler.source>${java.version}</maven.compiler.source>
		<maven.compiler.target>${java.version}</maven.compiler.target>

		<junit.version>4.12</junit.version>
		<mockito.version>1.10.19</mockito.version>
		<slf4j.version>1.7.9</slf4j.version>
	</properties>

	<dependencyManagement>
		<dependencies>
			<dependency>
				<groupId>org.slf4j</groupId>
				<artifactId>slf4j-api</artifactId>
				<version>${slf4j.version}</version>
			</dependency>
			<dependency>
				<groupId>junit</groupId>
				<artifactId>junit</artifactId>
				<version>${junit.version}</version>
			</dependency>
			<dependency>
				<groupId>org.mockito</groupId>
				<artifactId>mockito-all</artifactId>
				<version>${mockito.version}</version>
			</dependency>
		</dependencies>
	</dependencyManagement>

	<profiles>
		<profile>
			<id>dev</id>
			<activation>
				<activeByDefault>true</activeByDefault>
			</activation>
			<build>
				<pluginManagement>
					<plugins>
						<plugin>
							<groupId>org.apache.maven.plugins</groupId>
							<artifactId>maven-compiler-plugin</artifactId>
							<version>3.3</version>
							<configuration>
								<showDeprecation>true</showDeprecation>
								<showWarnings>true</showWarnings>
								<optimize>true</optimize>
								<compilerArgs>
									<arg>-Xlint</arg>
									<!-- <arg>-Werror</arg> -->
								</compilerArgs>
							</configuration>
						</plugin>
						<plugin>
							<groupId>org.apache.maven.plugins</groupId>
							<artifactId>maven-surefire-plugin</artifactId>
							<version>2.18</version>
						</plugin>
						<plugin>
							<groupId>org.jacoco</groupId>
							<artifactId>jacoco-maven-plugin</artifactId>
							<version>0.7.9</version>
						</plugin>
					</plugins>
				</pluginManagement>
				<plugins>
					<plugin>
						<groupId>org.apache.maven.plugins</groupId>
						<artifactId>maven-surefire-plugin</artifactId>
						<configuration>
							<!-- java Powermock fix -->
							<argLine>${argLine} -noverify</argLine>
						</configuration>
					</plugin>
					<plugin>
						<groupId>org.jacoco</groupId>
						<artifactId>jacoco-maven-plugin</artifactId>
						<configuration>
							<excludes>
								<!-- ignore entities -->
								<exclude>**/*Test.*</exclude>
							</excludes>
						</configuration>
						<executions>
							<execution>
								<id>default-prepare-agent</id>
								<goals>
									<goal>prepare-agent</goal>
								</goals>
							</execution>
							<execution>
								<id>default-report</id>
								<!-- default phase is verify -->
								<phase>prepare-package</phase>
								<goals>
									<goal>report</goal>
								</goals>
							</execution>
							<execution>
								<id>default-check</id>
								<goals>
									<goal>check</goal>
								</goals>
								<configuration>
									<rules>
										<!-- <rule> -->
										<!-- <element>BUNDLE</element> -->
										<!-- <limits> -->
										<!-- <limit> -->
										<!-- <counter>COMPLEXITY</counter> -->
										<!-- <value>COVEREDRATIO</value> -->
										<!-- <minimum>0.60</minimum> -->
										<!-- </limit> -->
										<!-- </limits> -->
										<!-- </rule> -->
									</rules>
								</configuration>
							</execution>
						</executions>
					</plugin>
				</plugins>
			</build>
		</profile>
	</profiles>

	<modules>
		<module>../oauth2-commons</module>
		<module>../oauth2-api</module>
		<module>../oauth2-client</module>
		<module>../oauth2-client-http-javase</module>
		<module>../oauth2-client-http-apache</module>
		<module>../oauth2-client-http-okhttp3</module>
		<module>../oauth2-databinding-gson</module>
		<module>../oauth2-databinding-jackson</module>
		<module>../oauth2-client-retrofit2</module>
		<module>../oauth2-samples</module>
	</modules>

</project>