<?xml version="1.0" encoding="UTF-8"?>
<project xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
	xmlns="http://maven.apache.org/POM/4.0.0"
	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>net.sf.openas2</groupId>
	<artifactId>OpenAS2</artifactId>
	<version>2.10.0</version>
	<name>OpenAS2</name>
	<packaging>pom</packaging>

	<description>
        This is the base Maven build file for the OpenAS2 project.
        The project comprises a server ,osgi bundle and a remote client component.
        There is a pom.xml for each of the components to build that component.
    </description>

	<url>https://sourceforge.net/projects/openas2</url>

	<licenses>
		<license>
			<name>BSD-2 License</name>
			<url>https://opensource.org/licenses/BSD-2-Clause</url>
			<distribution>repo</distribution>
		</license>
	</licenses>

	<modules>
		<module>Remote</module>
		<module>Server</module>
		<module>Bundle</module>
	</modules>

	<properties>
		<java.version>1.8</java.version>
	</properties>

	<dependencyManagement>
		<dependencies>
			<dependency>
				<groupId>org.osgi</groupId>
				<artifactId>org.osgi.core</artifactId>
				<version>4.3.1</version>
			</dependency>
			<dependency>
				<groupId>org.dom4j</groupId>
				<artifactId>dom4j</artifactId>
				<version>2.1.1</version>
			</dependency>
			<dependency>
				<groupId>org.bouncycastle</groupId>
				<artifactId>bcmail-jdk15on</artifactId>
				<version>1.62</version>
			</dependency>
			<dependency>
				<groupId>org.bouncycastle</groupId>
				<artifactId>bcpkix-jdk15on</artifactId>
				<version>1.62</version>
			</dependency>
			<dependency>
				<groupId>org.bouncycastle</groupId>
				<artifactId>bcprov-jdk15on</artifactId>
				<version>1.62</version>
			</dependency>
			<dependency>
				<groupId>org.bouncycastle</groupId>
				<artifactId>bcprov-ext-jdk15on</artifactId>
				<version>1.62</version>
			</dependency>
			<dependency>
				<groupId>org.bouncycastle</groupId>
				<artifactId>bcpg-jdk15on</artifactId>
				<version>1.62</version>
			</dependency>
			<dependency>
				<groupId>org.apache.commons</groupId>
				<artifactId>commons-lang3</artifactId>
				<version>3.7</version>
			</dependency>
			<dependency>
				<groupId>commons-cli</groupId>
				<artifactId>commons-cli</artifactId>
				<version>1.4</version>
			</dependency>
			<dependency>
				<groupId>commons-logging</groupId>
				<artifactId>commons-logging</artifactId>
				<version>1.2</version>
			</dependency>
			<dependency>
				<groupId>javax.mail</groupId>
				<artifactId>javax.mail-api</artifactId>
				<version>1.6.1</version>
			</dependency>
			<dependency>
				<groupId>com.sun.mail</groupId>
				<artifactId>javax.mail</artifactId>
				<version>1.6.1</version>
			</dependency>
			<dependency>
				<groupId>com.h2database</groupId>
				<artifactId>h2</artifactId>
				<version>1.4.197</version>
			</dependency>
			<!-- https://mvnrepository.com/artifact/org.apache.httpcomponents/httpcore -->
			<dependency>
				<groupId>org.apache.httpcomponents</groupId>
				<artifactId>httpcore</artifactId>
				<version>4.4.9</version>
			</dependency>
			<!-- https://mvnrepository.com/artifact/org.apache.httpcomponents/httpclient -->
			<dependency>
				<groupId>org.apache.httpcomponents</groupId>
				<artifactId>httpclient</artifactId>
				<version>4.5.5</version>
			</dependency>
			<dependency>
				<groupId>com.google.code.findbugs</groupId>
				<artifactId>findbugs</artifactId>
				<version>3.0.1</version>
				<scope>provided</scope> <!--not used in run-time -->
			</dependency>
			<dependency>
				<groupId>junit</groupId>
				<artifactId>junit</artifactId>
				<version>4.12</version>
				<scope>test</scope>
			</dependency>
			<dependency>
				<groupId>org.hamcrest</groupId>
				<artifactId>hamcrest-all</artifactId>
				<version>1.3</version>
				<scope>test</scope>
			</dependency>
			<!-- https://mvnrepository.com/artifact/org.mockito/mockito-core -->
			<dependency>
    				<groupId>org.mockito</groupId>
    				<artifactId>mockito-core</artifactId>
    				<version>2.18.3</version>
    				<scope>test</scope>
			</dependency>
			
			<dependency>
				<groupId>commons-io</groupId>
				<artifactId>commons-io</artifactId>
				<version>2.6</version>
			</dependency>
		</dependencies>
	</dependencyManagement>

	<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>

	<scm>
		<url>git@github.com:OpenAS2/OpenAs2App.git</url>
		<connection>scm:git:git@github.com:OpenAS2/OpenAs2App.git</connection>
		<developerConnection>scm:git:git@github.com:OpenAS2/OpenAs2App.git</developerConnection>
		<tag>HEAD</tag>
	</scm>

	<developers>
		<developer>
			<id>uhurusurfa</id>
			<name>Christopher Broderick</name>
			<email>uhurusurfa@users.sf.net</email>
		</developer>
	</developers>

	<build>
		<pluginManagement>
			<plugins>
				<plugin>
					<groupId>org.apache.maven.plugins</groupId>
					<artifactId>maven-compiler-plugin</artifactId>
					<version>3.6.1</version>
					<configuration>
						<source>${java.version}</source>
						<target>${java.version}</target>
					</configuration>
				</plugin>
				<plugin>
					<groupId>org.apache.maven.plugins</groupId>
					<artifactId>maven-jar-plugin</artifactId>
					<version>3.0.2</version>
					<configuration>
						<archive>
							<index>true</index>
							<manifest>
								<addClasspath>true</addClasspath>
								<mainClass>${mainClass}</mainClass>
								<addDefaultSpecificationEntries>true</addDefaultSpecificationEntries>
								<addDefaultImplementationEntries>true</addDefaultImplementationEntries>
							</manifest>
						</archive>
					</configuration>
				</plugin>
				<plugin>
					<groupId>org.apache.maven.plugins</groupId>
					<artifactId>maven-dependency-plugin</artifactId>
					<version>3.0.0</version>
					<executions>
						<execution>
							<id>copy-dependencies</id>
							<phase>package</phase>
							<goals>
								<goal>copy-dependencies</goal>
							</goals>
							<configuration>
								<outputDirectory>${project.build.directory}/dist/lib</outputDirectory>
								<overWriteReleases>false</overWriteReleases>
								<overWriteSnapshots>false</overWriteSnapshots>
								<overWriteIfNewer>true</overWriteIfNewer>
								<includeScope>runtime</includeScope>
							</configuration>
						</execution>
					</executions>
				</plugin>
				<plugin>
					<groupId>org.apache.maven.plugins</groupId>
					<artifactId>maven-antrun-plugin</artifactId>
					<version>1.8</version>
				</plugin>
				<plugin>
					<groupId>org.apache.maven.plugins</groupId>
					<artifactId>maven-site-plugin</artifactId>
					<version>3.6</version>
					<dependencies>
						<dependency>
							<groupId>org.apache.maven.wagon</groupId>
							<artifactId>wagon-ssh</artifactId>
							<version>2.12</version>
						</dependency>
					</dependencies>
				</plugin>
				<plugin>
					<groupId>org.apache.maven.plugins</groupId>
					<artifactId>maven-release-plugin</artifactId>
					<version>2.5.3</version>
					<configuration>
						<useReleaseProfile>false</useReleaseProfile>
						<releaseProfiles>release</releaseProfiles>
						<goals>deploy</goals>
					</configuration>
				</plugin>
				<plugin>
					<groupId>org.sonatype.plugins</groupId>
					<artifactId>nexus-staging-maven-plugin</artifactId>
					<version>1.6.7</version>
					<extensions>true</extensions>
					<configuration>
						<serverId>ossrh</serverId>
						<nexusUrl>https://oss.sonatype.org/</nexusUrl>
						<autoReleaseAfterClose>true</autoReleaseAfterClose>
					</configuration>
				</plugin>
			</plugins>
		</pluginManagement>
	</build>
	<profiles>
		<profile>
			<id>release</id>
			<build>
				<plugins>
					<plugin>
						<groupId>org.apache.maven.plugins</groupId>
						<artifactId>maven-source-plugin</artifactId>
						<version>3.0.1</version>
						<executions>
							<execution>
								<id>attach-sources</id>
								<goals>
									<goal>jar-no-fork</goal>
								</goals>
							</execution>
						</executions>
					</plugin>
					<plugin>
						<groupId>org.apache.maven.plugins</groupId>
						<artifactId>maven-javadoc-plugin</artifactId>
						<version>2.10.4</version>
						<executions>
							<execution>
								<id>attach-javadocs</id>
								<goals>
									<goal>jar</goal>
								</goals>
							</execution>
						</executions>
					</plugin>
					<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>
