<?xml version="1.0" encoding="UTF-8"?>
<!--
Copyright (C) 2014 TU Dortmund
This file is part of LearnLib, http://www.learnlib.de/.

LearnLib is free software; you can redistribute it and/or
modify it under the terms of the GNU Lesser General Public
License version 3.0 as published by the Free Software Foundation.

LearnLib is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
Lesser General Public License for more details.

You should have received a copy of the GNU Lesser General Public
License along with LearnLib; if not, see
http://www.gnu.de/documents/lgpl.en.html.
-->
<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>

	<!--
	================================= PROJECT INFO ==============================	
	-->
	<groupId>de.learnlib</groupId>
	<artifactId>learnlib-parent</artifactId>
	<version>0.11.2</version>
	<packaging>pom</packaging>
	<name>LearnLib</name>
	<url>http://learnlib.github.io/learnlib/maven-site/${project.version}</url>
	<description>A framework for active automata learning and experimentation</description>

	<licenses>
		<license>
			<name>GNU LESSER GENERAL PUBLIC LICENSE Version 3, 29 June 2007</name>
			<url>http://www.gnu.org/licenses/lgpl-3.0-standalone.html</url>
		</license>
	</licenses>

	<issueManagement>
		<url>https://github.com/LearnLib/learnlib/issues</url>
		<system>GitHub Issues</system>
	</issueManagement>

	<developers>
		<developer>
			<id>falkhowar</id>
			<name>Falk Howar</name>
			<email>falk.howar@gmail.com</email>
		</developer>
		<developer>
			<id>misberner</id>
			<name>Malte Isberner</name>
			<email>malte.isberner@gmail.com</email>
		</developer>
		<developer>
			<id>stovocor</id>
			<name>Stephan Windmüller</name>
			<email>stephan.windmueller@tu-dortmund.de</email>
		</developer>
		<developer>
			<id>merten</id>
			<name>Maik Merten</name>
			<email>maikmerten@googlemail.com</email>
		</developer>
		<developer>
			<id>oliverbauer8</id>
			<name>Oliver Bauer</name>
			<email>oliver.bauer@tu-dortmund.de</email>
		</developer>
	</developers>

	<!--	
	===============================	SCM =======================	
	-->
	<scm>
		<connection>scm:git:git@github.com:LearnLib/learnlib.git</connection>
		<developerConnection>scm:git:git@github.com:LearnLib/learnlib.git</developerConnection>
		<url>https://github.com/LearnLib/learnlib/tree/develop</url>
	  <tag>learnlib-0.11.2</tag>
  </scm>


	<!--	
	================================ SONATYPE PARENT ==============================	
	-->
	<parent>
			<groupId>org.sonatype.oss</groupId>
			<artifactId>oss-parent</artifactId>
			<version>9</version>
	</parent>

	<!--	
	================================= MODULES ===================================	
	-->
	<modules>
		<module>test-support</module>
		<module>build-tools</module>
		<module>core</module>
		<module>algorithms</module>
		<module>eqtests</module>
		<module>simulator</module>
		<module>utils</module>
		<module>filters</module>
		<module>drivers</module>
		<module>examples</module>
		<module>archetypes</module>
		
		<module>distribution</module>
	</modules>

	<!--	
	================================= PROPERTIES ================================
	-->
	<properties>
		<project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
		<project.reporting.outputEncoding>UTF-8</project.reporting.outputEncoding>
		<!--
			dependency versions
		-->
		<automatalib.version>0.5.2</automatalib.version>
		<testng.version>6.8.8</testng.version>
		<javadoc-plugin.version>2.10.1</javadoc-plugin.version>
		<compiler-plugin.version>3.1</compiler-plugin.version>
		<release-plugin.version>2.5.1</release-plugin.version>
		<checkstyle-plugin.version>2.10</checkstyle-plugin.version>
		<jdiff-plugin.version>1.0-beta-1</jdiff-plugin.version>
		<site-plugin.version>3.4</site-plugin.version>
		<reports-plugin.version>2.8</reports-plugin.version>
		<surefire-plugin.version>2.18.1</surefire-plugin.version>
		<failsafe-plugin.version>2.18.1</failsafe-plugin.version>
		<assembly-plugin.version>2.5.3</assembly-plugin.version>
		<resources-plugin.version>2.7</resources-plugin.version>
		<upload-plugin.version>1.1</upload-plugin.version>
		<exec-plugin.version>1.3.2</exec-plugin.version>
		<deploy-site-github.exec>deploy-site-github</deploy-site-github.exec>

		<trove4j.version>3.0.3</trove4j.version>
		
		<guava.version>18.0</guava.version>
		<findbugs.version>2.0.3</findbugs.version>
		
		<buildergen.version>0.1</buildergen.version>
		
		<!-- Javadoc links -->
		<java.apidocs>http://docs.oracle.com/javase/8/docs/api/</java.apidocs>
		<automatalib.apidocs>http://misberner.github.io/automatalib/maven-site/${automatalib.version}/apidocs/</automatalib.apidocs>
		<guava.apidocs>http://docs.guava-libraries.googlecode.com/git-history/v${guava.version}/javadoc/</guava.apidocs>
		<!-- Unfortunately, these are not version-sensitive -->
		<trove4j.apidocs>http://trove4j.sourceforge.net/javadocs/</trove4j.apidocs>
	</properties>


	<!--	
	================================= BUILD PLUGINS =============================	
	-->
	<build>
		<pluginManagement>
			<plugins>
				<plugin>
					<groupId>org.apache.maven.plugins</groupId>
					<artifactId>maven-compiler-plugin</artifactId>
					<version>${compiler-plugin.version}</version>
					<configuration>
						<fork>true</fork>
						<source>1.8</source>
						<target>1.8</target>
					</configuration>
				</plugin>
				<plugin>
					<groupId>org.apache.maven.plugins</groupId>
					<artifactId>maven-checkstyle-plugin</artifactId>
					<version>${checkstyle-plugin.version}</version>
					<configuration>
						<configLocation>config/sun_checks.xml</configLocation>
						<headerLocation>license-header.txt</headerLocation>
						<suppressionsLocation>checkstyle-suppressions.xml</suppressionsLocation>
					</configuration>
					<dependencies>
						<dependency>
							<groupId>${project.groupId}</groupId>
							<artifactId>learnlib-build-tools</artifactId>
							<version>${project.version}</version>
						</dependency>
					</dependencies>
				</plugin>
				<plugin>
					<groupId>org.apache.maven.plugins</groupId>
					<artifactId>maven-site-plugin</artifactId>
					<version>${site-plugin.version}</version>
					<executions>
						<execution>
							<id>attach-descriptor</id>
							<goals>
								<goal>attach-descriptor</goal>
							</goals>
						</execution>
						<!-- Skip site creation; this will be done by deploy-site-github -->
						<execution>
							<id>default-site</id>
							<phase>site</phase>
							<configuration>
								<skip>true</skip>
							</configuration>
						</execution>
					</executions>
					<configuration>
						<skipDeploy>true</skipDeploy>
					</configuration>
				</plugin>
				<plugin>
					<groupId>org.codehaus.mojo</groupId>
					<artifactId>exec-maven-plugin</artifactId>
					<version>${exec-plugin.version}</version>
				</plugin>
				<plugin>
					<groupId>org.apache.maven.plugins</groupId>
					<artifactId>maven-surefire-plugin</artifactId>
					<version>${surefire-plugin.version}</version>
				</plugin>
				<plugin>
					<groupId>org.apache.maven.plugins</groupId>
					<artifactId>maven-failsafe-plugin</artifactId>
					<version>${failsafe-plugin.version}</version>
					<executions>
						<execution>
							<goals>
								<goal>integration-test</goal>
								<goal>verify</goal>
							</goals>
						</execution>
					</executions>
				</plugin>
				<plugin>
					<groupId>org.apache.maven.plugins</groupId>
					<artifactId>maven-assembly-plugin</artifactId>
					<version>${assembly-plugin.version}</version>
				</plugin>
				<plugin>
					<groupId>org.apache.maven.plugins</groupId>
					<artifactId>maven-release-plugin</artifactId>
					<version>${release-plugin.version}</version>
					<configuration>
						<!--
						We use a property rather than a profile such that several different profiles
						can be activated upon a release, without us having to add them here
						-->
						<arguments>-Psonatype-oss-release -Dlearnlib.release=true -Dmaven.javadoc.failOnError=false</arguments>
						<!-- False to allow rebasing in case of errors -->
						<pushChanges>false</pushChanges>
						<!-- Automatically use the parent version for all submodules, do not prompt for each one -->
						<autoVersionSubmodules>true</autoVersionSubmodules>
						<!-- Use prefix learnlib, not learnlib-parent -->
						<tagNameFormat>learnlib-@{version}</tagNameFormat>
						<!-- The default "clean verify" causes javadoc and archetype integration tests to fail -->
						<preparationGoals>clean install</preparationGoals>
					</configuration>
				</plugin>
				<plugin>
					<groupId>com.atlassian.maven.plugins</groupId>
					<artifactId>maven-upload-plugin</artifactId>
					<version>${upload-plugin.version}</version>
					<configuration>
						<serverId>learnlib-de</serverId>
						<url>sftp://www155.your-server.de/</url>
					</configuration>
				</plugin>
				<plugin>
					<groupId>org.apache.maven.plugins</groupId>
					<artifactId>maven-javadoc-plugin</artifactId>
					<version>${javadoc-plugin.version}</version>
					<configuration>
						<quiet>false</quiet>
						<source>1.8</source>
						<verbose>true</verbose>
						<detectLinks>true</detectLinks>
						<linksource>false</linksource>
						<failOnError>false</failOnError>
						<links>
							<link>${java.apidocs}</link>
							<link>${trove4j.apidocs}</link>
							<link>${guava.apidocs}</link>
							<link>${automatalib.apidocs}</link>
						</links>
					</configuration>
				</plugin>
				<!-- This gets rid of the nasty "maven-enforcer-plugin will be ignored" warning by m2e -->
				<plugin>
					<groupId>org.eclipse.m2e</groupId>
					<artifactId>lifecycle-mapping</artifactId>
					<version>1.0.0</version>
					<configuration>
						<lifecycleMappingMetadata>
							<pluginExecutions>
								<pluginExecution>
									<pluginExecutionFilter>
										<groupId>org.apache.maven.plugins</groupId>
										<artifactId>maven-enforcer-plugin</artifactId>
										<versionRange>[1.0.0,)</versionRange>
										<goals>
											<goal>enforce</goal>
										</goals>
									</pluginExecutionFilter>
									<action>
										<ignore />
									</action>
								</pluginExecution>
							</pluginExecutions>
						</lifecycleMappingMetadata>
					</configuration>
				</plugin>
			</plugins>
		</pluginManagement>
		
		<plugins>
			<plugin>
				<groupId>org.codehaus.mojo</groupId>
				<artifactId>exec-maven-plugin</artifactId>
				<executions>
					<!-- Deploy site @ GitHub pages -->
					<!--
						Note: In order to be able to deploy the Maven site,
						you need the script deploy-site-github to reside
						in your PATH, or manually specify the path to the
						executable script using the "deploy-site-github.exec"
						property.
						You can download the shell script from this URL:
						https://raw.github.com/misberner/shell-scripts/master/maven/deploy-site-github.sh
					-->
					<execution>
						<id>deploy-site-github</id>
						<inherited>false</inherited>
						<phase>site-deploy</phase>
						<goals>
							<goal>exec</goal>
						</goals>
						<configuration>
							<executable>${deploy-site-github.exec}</executable>
							<workingDirectory>${project.basedir}</workingDirectory>
							<arguments>
								<argument>-p</argument> <!-- Purge contents before copying -->
								<argument>-P/maven-site</argument>
								<argument>-V</argument>
								<argument>-l</argument>
							</arguments>
						</configuration>
					</execution>
				</executions>
			</plugin>
		</plugins>
		
		<extensions>
			<extension>
				<groupId>org.apache.maven.wagon</groupId>
				<artifactId>wagon-ssh</artifactId>
				<version>2.6</version>
			</extension>
		</extensions>
	</build>

	<!--
	================================= REPORTING PLUGINS ==============================	
	-->
	<reporting>
		<plugins>
			<plugin>
				<groupId>org.apache.maven.plugins</groupId>
				<artifactId>maven-project-info-reports-plugin</artifactId>
				<version>${reports-plugin.version}</version>
				<reportSets>
					<reportSet>
						<reports>
							<report>index</report>
							<report>license</report>
							<report>project-team</report>
							<report>mailing-list</report>
							<report>issue-tracking</report>
							<report>scm</report>
							<report>dependencies</report>
							<report>dependency-info</report>
							<report>modules</report>
						</reports>
					</reportSet>
				</reportSets>
			</plugin>
			<plugin>
				<groupId>org.apache.maven.plugins</groupId>
				<artifactId>maven-javadoc-plugin</artifactId>
				<version>${javadoc-plugin.version}</version>
				<configuration>
					<quiet>false</quiet>
					<source>1.8</source>
					<verbose>true</verbose>
					<detectLinks>true</detectLinks>
					<linksource>false</linksource>
					<failOnError>false</failOnError>
					<links>
						<link>${java.apidocs}</link>
						<link>${trove4j.apidocs}</link>
						<link>${guava.apidocs}</link>
						<link>${automatalib.apidocs}</link>
					</links>
				</configuration>
				<reportSets>
					<reportSet>
						<id>non-aggregate</id>
						<reports>
							<report>javadoc</report>
						</reports>
					</reportSet>
					<reportSet>
						<id>aggregate</id>
						<inherited>false</inherited>
						<reports>
							<report>aggregate</report>
						</reports>
					</reportSet>
				</reportSets>
			</plugin>
			<!-- jdiff-maven-plugin not in central! -->
			<!--
			<plugin>
				<groupId>org.codehaus.mojo</groupId>
				<artifactId>jdiff-maven-plugin</artifactId>
				<version>${jdiff-plugin.version}</version>
			</plugin>
			-->
		</plugins>
	</reporting>

	<!--	
	===============================	PROFILES =======================	
	-->
	<profiles>
		<profile>
			<id>integration-tests</id>
			<activation>
				<property>
					<name>learnlib.release</name>
					<value>true</value>
				</property>
			</activation>
			<build>
				<plugins>
					<plugin>
						<groupId>org.apache.maven.plugins</groupId>
						<artifactId>maven-failsafe-plugin</artifactId>
					</plugin>
				</plugins>
			</build>
		</profile>
		<profile>
			<id>netbeans-private-testng</id>
			<activation>
				<property>
					<name>netbeans.testng.action</name>
				</property>
			</activation>
			<build>
				<plugins>
					<plugin>
						<groupId>org.apache.maven.plugins</groupId>
						<artifactId>maven-surefire-plugin</artifactId>
						<configuration>
							<suiteXmlFiles>
								<suiteXmlFile>target/nb-private/testng-suite.xml</suiteXmlFile>
							</suiteXmlFiles>
						</configuration>
					</plugin>
				</plugins>
			</build>
		</profile>
		<profile>
			<id>binary-release</id>
			<activation>
				<property>
					<name>learnlib.release</name>
					<value>true</value>
				</property>
			</activation>
			<build>
				<plugins>
					<!-- aggregate javadoc of modules in one jar -->
					<!--
						Note: we don't use the assembly plugin here, since then
						inter-module links wouldn't work correctly
					-->
					<!-- Moved to distribution -->
					<!-- 
					<plugin>
						<groupId>org.apache.maven.plugins</groupId>
						<artifactId>maven-javadoc-plugin</artifactId>
						<inherited>false</inherited>
						<configuration>
							<finalName>learnlib-${project.version}</finalName>
						</configuration>
						<executions>
							<execution>
								<id>aggregate</id>
								<goals>
									<goal>aggregate-jar</goal>
								</goals>
								<phase>package</phase>
							</execution>
						</executions>
					</plugin>
					<plugin>
						<groupId>com.atlassian.maven.plugins</groupId>
						<artifactId>maven-upload-plugin</artifactId>
						<inherited>false</inherited>
						<executions>
							<execution>
								<id>upload-javadoc-jar</id>
								<phase>site-deploy</phase>
								<goals>
									<goal>upload</goal>
								</goals>
								<configuration>
									<resourceSrc>${project.build.directory}/learnlib-${project.version}-javadoc.jar</resourceSrc>
									<resourceDest>/files/releases/${project.version}/</resourceDest>
								</configuration>
							</execution>
						</executions>
					</plugin>
				-->
				</plugins>
			</build>
		</profile>
	</profiles>

	<!--	
	===============================	DEFAULT DEP. VERSIONS =======================	
	-->
	<dependencyManagement>
		<dependencies>
			<dependency>
				<groupId>de.learnlib</groupId>
				<artifactId>learnlib-core</artifactId>
				<version>${project.version}</version>
			</dependency>
			<dependency>
				<groupId>de.learnlib</groupId>
				<artifactId>learnlib-algorithm-features</artifactId>
				<version>${project.version}</version>
			</dependency>
			<dependency>
				<groupId>de.learnlib</groupId>
				<artifactId>learnlib-lstar-baseline</artifactId>
				<version>${project.version}</version>
			</dependency>
			<dependency>
				<groupId>de.learnlib</groupId>
				<artifactId>learnlib-lstar-generic</artifactId>
				<version>${project.version}</version>
			</dependency>
			<dependency>
				<groupId>de.learnlib</groupId>
				<artifactId>learnlib-dhc</artifactId>
				<version>${project.version}</version>
			</dependency>
			<dependency>
				<groupId>de.learnlib</groupId>
				<artifactId>learnlib-ttt</artifactId>
				<version>${project.version}</version>
			</dependency>
			<dependency>
				<groupId>de.learnlib</groupId>
				<artifactId>learnlib-basic-eqtests</artifactId>
				<version>${project.version}</version>
			</dependency>
			<dependency>
				<groupId>de.learnlib</groupId>
				<artifactId>learnlib-simulator</artifactId>
				<version>${project.version}</version>
			</dependency>
			<dependency>
				<groupId>de.learnlib</groupId>
				<artifactId>learnlib-counterexamples</artifactId>
				<version>${project.version}</version>
			</dependency>
			<dependency>
				<groupId>de.learnlib</groupId>
				<artifactId>learnlib-cache</artifactId>
				<version>${project.version}</version>
			</dependency>
			<dependency>
				<groupId>de.learnlib</groupId>
				<artifactId>learnlib-reuse</artifactId>
				<version>${project.version}</version>
			</dependency>			
			<dependency>
				<groupId>de.learnlib</groupId>
				<artifactId>learnlib-drivers-basic</artifactId>
				<version>${project.version}</version>
			</dependency>
			<dependency>
				<groupId>de.learnlib</groupId>
				<artifactId>learnlib-parallelism</artifactId>
				<version>${project.version}</version>
			</dependency>
			<dependency>
				<groupId>de.learnlib</groupId>
				<artifactId>learnlib-nlstar</artifactId>
				<version>${project.version}</version>
			</dependency>
			
			<dependency>
				<groupId>de.learnlib</groupId>
				<artifactId>learnlib-discrimination-tree</artifactId>
				<version>${project.version}</version>
			</dependency>
			
			<dependency>
				<groupId>de.learnlib</groupId>
				<artifactId>learnlib-kearns-vazirani</artifactId>
				<version>${project.version}</version>
			</dependency>
			
			<dependency>
				<groupId>de.learnlib</groupId>
				<artifactId>learnlib-mapper</artifactId>
				<version>${project.version}</version>
			</dependency>
			
			<dependency>
				<groupId>de.learnlib</groupId>
				<artifactId>learnlib-acex</artifactId>
				<version>${project.version}</version>
			</dependency>

			<!-- LearnLib tests -->
			<dependency>
				<groupId>de.learnlib.testsupport</groupId>
				<artifactId>learnlib-learning-examples</artifactId>
				<version>${project.version}</version>
				<scope>test</scope>
			</dependency>

			<dependency>
				<groupId>de.learnlib.testsupport</groupId>
				<artifactId>learnlib-learner-it-support</artifactId>
				<version>${project.version}</version>
				<scope>test</scope>
			</dependency>

			<!-- Import AutomataLib dependencies -->
			<dependency>
				<groupId>net.automatalib</groupId>
				<artifactId>automata-parent</artifactId>
				<version>${automatalib.version}</version>
				<type>pom</type>
				<scope>import</scope>
			</dependency>

			<!-- TestNG -->
			<dependency>
				<groupId>org.testng</groupId>
				<artifactId>testng</artifactId>
				<version>${testng.version}</version>
				<scope>test</scope>
			</dependency>


			<!-- GNU Trove -->
			<dependency>
				<groupId>net.sf.trove4j</groupId>
				<artifactId>trove4j</artifactId>
				<version>${trove4j.version}</version>
			</dependency>

			<!-- Guava -->
			<dependency>
				<groupId>com.google.guava</groupId>
				<artifactId>guava</artifactId>
				<version>${guava.version}</version>
			</dependency>

			<!-- FindBugs - JSR 305 Annotations (@Nullable, @Nonnull, ...) -->
			<dependency>
				<groupId>com.google.code.findbugs</groupId>
				<artifactId>jsr305</artifactId>
				<version>${findbugs.version}</version>
			</dependency>

			<!-- BuilderGen -->
			<dependency>
				<groupId>com.github.misberner.buildergen</groupId>
				<artifactId>buildergen</artifactId>
				<version>${buildergen.version}</version>
				<!-- Compile-time only -->
				<scope>provided</scope>
			</dependency>

		</dependencies>
	</dependencyManagement>
	
	<pluginRepositories>
		<!-- Ensure preference over the atlassian plugin repository -->
		<pluginRepository>
			<releases>
				<enabled>true</enabled>
			</releases>
			<snapshots>
				<enabled>false</enabled>
			</snapshots>
			<id>central</id>
			<url>http://repo1.maven.org/maven2</url>
		</pluginRepository>
		
		<!-- For maven-upload-plugin -->
		<pluginRepository>
			<id>atlassian-public</id>
			<url>https://maven.atlassian.com/repository/public</url>
			<releases>
				<enabled>true</enabled>
				<checksumPolicy>warn</checksumPolicy>
			</releases>
		</pluginRepository>
	</pluginRepositories>

	<!--
	================================= DISTRIBUTION ==============================	
	-->
	<distributionManagement>
		<!-- Dummy - this will NOT actually be used, but is required for mvn site:stage -->
		<!-- Use build-tools/deploy-site.sh for site deployment on GitHub pages -->
		<site>
			<id>local</id>
			<url>file://${user.home}/learnlib-site</url>
		</site>
	</distributionManagement>
</project>
