<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>io.github.furrrlo</groupId>
	<artifactId>unique4j-parent</artifactId>
	<version>2.0.0</version>
	<packaging>pom</packaging>

	<name>Unique4j</name>
	<url>https://github.com/Furrrlo/unique4j</url>
	<description>Java library to allow only single instance of a java application to run and enable communication between first instance and subsequent instances</description>

	<developers>
		<developer>
			<name>Francesco Ferlin</name>
			<url>https://github.com/Furrrlo/</url>
		</developer>
		<developer>
			<name>Pratanu Mandal</name>
			<email>pratanu.mandal@gmail.com</email>
			<url>https://pratanumandal.tk/</url>
		</developer>
	</developers>

	<licenses>
		<license>
			<name>Apache License, Version 2.0</name>
			<url>https://www.apache.org/licenses/LICENSE-2.0.txt</url>
			<distribution>repo</distribution>
		</license>
	</licenses>

	<scm>
		<url>https://github.com/Furrrlo/unique4j</url>
		<connection>scm:git:https://github.com/Furrrlo/unique4j.git</connection>
		<developerConnection>scm:git:https://github.com/Furrrlo/unique4j.git</developerConnection>
	  <tag>v2.0.0</tag>
  </scm>

	<properties>
		<project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
	</properties>

	<modules>
		<module>unique4j</module>
		<module>unique4j-tests</module>
		<module>unique4j-junixsocket</module>
		<!-- Last module should be one we want to deploy, as per documentation -->
		<module>unique4j-unix-socket-channel</module>
	</modules>

	<build>
		<plugins>
			<plugin>
				<groupId>org.apache.maven.plugins</groupId>
				<artifactId>maven-release-plugin</artifactId>
				<version>2.5.3</version>
				<dependencies>
					<dependency>
						<groupId>org.apache.maven.scm</groupId>
						<artifactId>maven-scm-provider-gitexe</artifactId>
						<version>1.9</version>
					</dependency>
				</dependencies>
				<configuration>
					<tagNameFormat>v@{project.version}</tagNameFormat>
					<autoVersionSubmodules>true</autoVersionSubmodules>
					<releaseProfiles>release</releaseProfiles>
				</configuration>
			</plugin>
			<plugin>
				<groupId>org.apache.maven.plugins</groupId>
				<artifactId>maven-deploy-plugin</artifactId>
				<version>2.8.2</version>
				<configuration>
					<skip>true</skip>
				</configuration>
			</plugin>
			<plugin>
				<groupId>org.sonatype.plugins</groupId>
			    <artifactId>nexus-staging-maven-plugin</artifactId>
			    <version>1.6.13</version>
			    <executions>
				    <execution>
					    <id>default-deploy</id>
					    <phase>deploy</phase>
					    <goals>
					    	<goal>deploy</goal>
					    </goals>
				    </execution>
			    </executions>
			    <configuration>
			    	<serverId>ossrh</serverId>
			    	<nexusUrl>https://s01.oss.sonatype.org</nexusUrl>
			    </configuration>
			</plugin>
			<plugin>
				<groupId>org.apache.maven.plugins</groupId>
				<artifactId>maven-source-plugin</artifactId>
				<version>3.1.0</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>3.1.1</version>
				<executions>
					<execution>
						<id>attach-javadocs</id>
						<goals>
							<goal>jar</goal>
						</goals>
					</execution>
				</executions>
			</plugin>
		</plugins>
	</build>

	<profiles>
		<profile>
			<id>release</id>
			<distributionManagement>
				<repository>
					<id>ossrh</id>
					<url>https://s01.oss.sonatype.org/service/local/staging/deploy/maven2/</url>
				</repository>
			</distributionManagement>
			<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>
