<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/maven-v4_0_0.xsd">

	<modelVersion>4.0.0</modelVersion>

	<groupId>org.visualdataweb.vowl.owl2vowl</groupId>
	<artifactId>OWL2VOWL</artifactId>
	<version>0.3.7</version>
	<packaging>${packaging.type}</packaging>
	<name>${project.groupId}:${project.artifactId}</name>
	<description>Owl2Vowl is an ontology converter used to convert the given ontology to a json
		format that is used in the WebVOWL visualization. See
		https://github.com/VisualDataWeb/WebVOWL or http://vowl.visualdataweb.org/.
	</description>
	<url>https://github.com/VisualDataWeb/OWL2VOWL</url>

	<properties>
		<java.version>1.8</java.version>
		<project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
		<mainClass>de.uni_stuttgart.vis.vowl.owl2vowl.ConsoleMain</mainClass>
		<packaging.type>jar</packaging.type>
		<authors>Vincent Link, Steffen Lohmann, Eduard Marbach, Vitalis Wiens</authors>
	</properties>

	<developers>
		<developer>
			<name>Eduard Marbach</name>
			<email>mail@eduard-marbach.de</email>
			<organization>University Stuttgart</organization>
			<organizationUrl>https://github.com/BlackDark</organizationUrl>
		</developer>
		<developer>
			<name>Vincent Link</name>
			<email>mail@linkvt.de</email>
			<organization>University Stuttgart</organization>
			<organizationUrl>https://github.com/linkvt</organizationUrl>
		</developer>
	</developers>

	<licenses>
		<license>
			<name>MIT License</name>
			<url>http://www.opensource.org/licenses/mit-license.php</url>
		</license>
	</licenses>

	<scm>
		<connection>scm:git:git@github.com:VisualDataWeb/OWL2VOWL.git</connection>
		<developerConnection>scm:git:git@github.com:VisualDataWeb/OWL2VOWL.git</developerConnection>
		<url>git@github.com:VisualDataWeb/OWL2VOWL.git</url>
		<tag>HEAD</tag>
	</scm>

	<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>

	<dependencyManagement>
		<dependencies>
			<dependency>
				<!-- Import dependency management from Spring Boot -->
				<groupId>org.springframework.boot</groupId>
				<artifactId>spring-boot-dependencies</artifactId>
				<version>1.5.6.RELEASE</version>
				<type>pom</type>
				<scope>import</scope>
			</dependency>
		</dependencies>
	</dependencyManagement>


	<build>
		<resources>
			<resource>
				<directory>src/main/resources</directory>
				<filtering>true</filtering>
				<includes>
					<include>*.properties</include>
				</includes>
			</resource>
			<resource>
				<directory>src/main/resources</directory>
				<filtering>false</filtering>
				<excludes>
					<exclude>*.properties</exclude>
				</excludes>
			</resource>
		</resources>
		<plugins>
			<plugin>
				<groupId>org.apache.maven.plugins</groupId>
				<artifactId>maven-compiler-plugin</artifactId>
				<version>3.3</version>
				<configuration>
					<source>1.8</source>
					<target>1.8</target>
				</configuration>
			</plugin>
			<plugin>
				<groupId>org.sonatype.plugins</groupId>
				<artifactId>nexus-staging-maven-plugin</artifactId>
				<version>1.6.6</version>
				<extensions>true</extensions>
				<configuration>
					<serverId>ossrh</serverId>
					<nexusUrl>https://oss.sonatype.org/</nexusUrl>
					<autoReleaseAfterClose>true</autoReleaseAfterClose>
				</configuration>
			</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>
		</plugins>
	</build>

	<profiles>

		<!-- Deactivate the strong JDoc linting which often breaks the mvn lifecycle -->
		<profile>
			<id>disable-java8-doclint</id>
			<activation>
				<jdk>[1.8,)</jdk>
			</activation>
			<properties>
				<additionalparam>-Xdoclint:none</additionalparam>
			</properties>
		</profile>

		<!-- LIBRARY PROFILE (with signing) -->
		<profile>
			<id>release</id>
			<properties>
				<packaging.type>jar</packaging.type>
			</properties>
			<build>
				<plugins>
					<plugin>
						<groupId>org.apache.maven.plugins</groupId>
						<artifactId>maven-deploy-plugin</artifactId>
						<configuration>
							<updateReleaseInfo>true</updateReleaseInfo>
						</configuration>
					</plugin>
					<plugin>
						<groupId>org.apache.maven.plugins</groupId>
						<artifactId>maven-source-plugin</artifactId>
						<version>2.4</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.3</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>

		<!-- JAR GENERATION PROFILE -->
		<profile>
			<id>standalone-release</id>
			<properties>
				<packaging.type>jar</packaging.type>
			</properties>
			<activation>
				<property>
					<name>env</name>
					<value>standalone</value>
				</property>
			</activation>

			<dependencies>

				<dependency>
					<groupId>org.springframework.boot</groupId>
					<artifactId>spring-boot-starter-log4j2</artifactId>
				</dependency>

				<dependency>
					<groupId>org.apache.logging.log4j</groupId>
					<artifactId>log4j-core</artifactId>
					<version>2.17.1</version>
				</dependency>

				<dependency>
					<groupId>org.apache.logging.log4j</groupId>
					<artifactId>log4j-slf4j-impl</artifactId>
					<version>2.7</version>
				</dependency>

				<dependency>
					<groupId>org.slf4j</groupId>
					<artifactId>slf4j-api</artifactId>
					<version>1.7.25</version>
				</dependency>

				<dependency>
					<groupId>org.slf4j</groupId>
					<artifactId>jcl-over-slf4j</artifactId>
					<version>1.7.25</version>
				</dependency>

				<dependency>
					<groupId>org.slf4j</groupId>
					<artifactId>jul-to-slf4j</artifactId>
					<version>1.7.25</version>
				</dependency>

			</dependencies>

			<build>
				<plugins>
					<plugin>
						<groupId>org.apache.maven.plugins</groupId>
						<artifactId>maven-shade-plugin</artifactId>
						<version>3.0.0</version>
						<dependencies>
							<dependency>
								<groupId>org.springframework.boot</groupId>
								<artifactId>spring-boot-maven-plugin</artifactId>
								<version>1.5.6.RELEASE</version>
							</dependency>
						</dependencies>
						<configuration>

						</configuration>
						<executions>
							<execution>
								<phase>package</phase>
								<goals>
									<goal>shade</goal>
								</goals>
								<configuration>
									<minimizeJar>true</minimizeJar>
									<shadedArtifactAttached>true</shadedArtifactAttached>
									<shadedClassifierName>shaded</shadedClassifierName>

									<transformers>
										<!-- necessary spring configuration -->
										<transformer
												implementation="org.apache.maven.plugins.shade.resource.AppendingTransformer">
											<resource>META-INF/spring.handlers</resource>
										</transformer>
										<transformer
												implementation="org.apache.maven.plugins.shade.resource.AppendingTransformer">
											<resource>META-INF/spring.schemas</resource>
										</transformer>
										<transformer
												implementation="org.apache.maven.plugins.shade.resource.AppendingTransformer">
											<resource>META-INF/spring.factories</resource>
										</transformer>
										<transformer implementation="org.apache.maven.plugins.shade.resource.IncludeResourceTransformer">
											<resource>META-INF/LICENSE</resource>
											<file>LICENSE.txt</file>
										</transformer>
										<transformer implementation="org.apache.maven.plugins.shade.resource.ApacheLicenseResourceTransformer">
										</transformer>
										<!-- add Main-Class to manifest file -->
										<transformer
												implementation="org.apache.maven.plugins.shade.resource.ManifestResourceTransformer">
											<manifestEntries>
												<Main-Class>${mainClass}</Main-Class>
												<Build-Version>${project.version}</Build-Version>
												<Authors>${authors}</Authors>
											</manifestEntries>
										</transformer>
									</transformers>

									<artifactSet>
										<excludes>
											<exclude>org.springframework:*</exclude>
											<exclude>org.springframework.*</exclude>
											<exclude>org.apache.tomcat.*</exclude>
										</excludes>
									</artifactSet>

									<filters>
										<filter>
											<artifact>net.sourceforge.owlapi:*</artifact>
											<includes>
												<include>**</include>
											</includes>
										</filter>
										<filter>
											<artifact>org.eclipse.rdf4j:*</artifact>
											<includes>
												<include>**</include>
											</includes>
										</filter>
										<filter>
											<artifact>commons-io:commons-io</artifact>
											<includes>
												<include>**</include>
											</includes>
										</filter>
										<filter>
											<artifact>com.google.guava:*</artifact>
											<includes>
												<include>**</include>
											</includes>
										</filter>
										<filter>
											<artifact>org.apache.logging.log4j:*</artifact>
											<includes>
												<include>**</include>
											</includes>
										</filter>
										<filter>
											<artifact>*:*</artifact>
											<excludes>
												<exclude>META-INF/license/**</exclude>
												<exclude>META-INF/maven/**</exclude>
												<exclude>LICENSE</exclude>
												<exclude>NOTICE</exclude>
												<exclude>/*.txt</exclude>
												<exclude>build.properties</exclude>
											</excludes>
										</filter>
									</filters>
								</configuration>
							</execution>
						</executions>
					</plugin>
					<plugin>
						<groupId>org.apache.maven.plugins</groupId>
						<artifactId>maven-scm-plugin</artifactId>
						<version>1.9.4</version>
						<configuration>
							<connectionType>connection</connectionType>
							<message>Update to ${project.version}</message>
						</configuration>
					</plugin>
				</plugins>
			</build>
		</profile>

		<!-- WAR GENERATION PROFILE -->
		<profile>
			<id>war-release</id>
			<properties>
				<packaging.type>war</packaging.type>
				<mainClass>de.uni_stuttgart.vis.vowl.owl2vowl.ServerMain</mainClass>
			</properties>
			<activation>
				<property>
					<name>env</name>
					<value>war</value>
				</property>
			</activation>
			<dependencies>

				<dependency>
					<groupId>org.springframework.boot</groupId>
					<artifactId>spring-boot-starter-tomcat</artifactId>
					<scope>provided</scope>
				</dependency>
			</dependencies>
			<build>
				<finalName>owl2vowl</finalName>

				<plugins>
					<plugin>
						<artifactId>maven-compiler-plugin</artifactId>
						<version>3.1</version>
						<configuration>
							<source>1.8</source>
							<target>1.8</target>
						</configuration>
					</plugin>
					<plugin>
						<artifactId>maven-war-plugin</artifactId>
						<version>2.4</version>
						<configuration>
							<failOnMissingWebXml>false</failOnMissingWebXml>
						</configuration>
					</plugin>
					<plugin>
						<groupId>org.springframework.boot</groupId>
						<artifactId>spring-boot-maven-plugin</artifactId>
						<version>1.5.6.RELEASE</version>
						<executions>
							<execution>
								<goals>
									<goal>repackage</goal>
								</goals>
							</execution>
						</executions>
						<configuration>
							<mainClass>${mainClass}</mainClass>
						</configuration>
					</plugin>
				</plugins>
			</build>
		</profile>
	</profiles>

	<dependencies>
		<!-- For local booting required -->
		<dependency>
			<groupId>org.springframework.boot</groupId>
			<artifactId>spring-boot-starter-web</artifactId>
			<exclusions>
				<exclusion>
					<groupId>org.springframework.boot</groupId>
					<artifactId>spring-boot-starter-logging</artifactId>
				</exclusion>
			</exclusions>
		</dependency>

		<dependency>
			<groupId>net.sourceforge.owlapi</groupId>
			<artifactId>owlapi-distribution</artifactId>
			<version>5.1.1</version>
		</dependency>

		<dependency>
			<groupId>org.apache.servicemix.bundles</groupId>
			<artifactId>org.apache.servicemix.bundles.collections-generic</artifactId>
			<version>4.01_1</version>
		</dependency>

		<dependency>
			<groupId>org.apache.commons</groupId>
			<artifactId>commons-lang3</artifactId>
			<version>3.6</version>
		</dependency>

		<dependency>
			<groupId>commons-io</groupId>
			<artifactId>commons-io</artifactId>
			<version>2.5</version>
		</dependency>

		<dependency>
			<groupId>org.apache.logging.log4j</groupId>
			<artifactId>log4j-api</artifactId>
			<version>2.7</version>
		</dependency>

		<dependency>
			<groupId>commons-cli</groupId>
			<artifactId>commons-cli</artifactId>
			<version>1.3.1</version>
		</dependency>

		<dependency>
			<groupId>org.codehaus.jackson</groupId>
			<artifactId>jackson-mapper-asl</artifactId>
			<version>1.9.13</version>
		</dependency>

		<dependency>
			<groupId>org.springframework.boot</groupId>
			<artifactId>spring-boot-starter-test</artifactId>
			<scope>test</scope>
		</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>

		<dependency>
			<groupId>org.mockito</groupId>
			<artifactId>mockito-all</artifactId>
			<version>1.10.19</version>
			<scope>test</scope>
		</dependency>

		<dependency>
			<groupId>org.powermock</groupId>
			<artifactId>powermock-api-mockito</artifactId>
			<version>1.6.4</version>
			<scope>test</scope>
		</dependency>

		<dependency>
			<groupId>org.powermock</groupId>
			<artifactId>powermock-module-junit4</artifactId>
			<version>1.6.4</version>
			<scope>test</scope>
		</dependency>

		<dependency>
			<groupId>org.apache.logging.log4j</groupId>
			<artifactId>log4j-slf4j-impl</artifactId>
			<version>2.7</version>
			<scope>test</scope>
		</dependency>

		<dependency>
			<groupId>org.apache.logging.log4j</groupId>
			<artifactId>log4j-core</artifactId>
			<version>2.17.1</version>
			<scope>test</scope>
		</dependency>

	</dependencies>

	<pluginRepositories>
		<pluginRepository>
			<id>spring-releases</id>
			<url>https://repo.spring.io/libs-release</url>
		</pluginRepository>
	</pluginRepositories>

</project>
