<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>li.moskito</groupId>
	<artifactId>scribble</artifactId>
	<version>0.0.1</version>
	<packaging>jar</packaging>

	<name>${project.groupId}:${project.artifactId}</name>
	<description>A testing framework for developing unit tests that required
	a JCR repository. The framework contains mock repositories, assertion
	and other helper classes.
	</description>
	<url>https://github.com/moskitoli/scribble</url>

	<properties>
		<!-- Common Libraries Versions -->
		<slf4j.version>1.7.6</slf4j.version>
		<log4j.version>2.0-rc1</log4j.version>
		<!-- Test lib versions -->
		<junit.version>4.11</junit.version>
		<mockito.version>1.9.5</mockito.version>

		<!-- javax Versions -->
		<javax.jcr.version>2.0</javax.jcr.version>
		<javax.javaee-api.version>7.0</javax.javaee-api.version>
		<javax.ws.rs-api.version>2.0.1</javax.ws.rs-api.version>
		<jboss.resteasy.version>3.0.10.Final</jboss.resteasy.version>

		<!-- Apache Library Version -->
		<apache.commons.io.version>2.4</apache.commons.io.version>
		<apache.deltaspike.version>1.1.0</apache.deltaspike.version>
		<apache.jackrabbit.version>2.8.0</apache.jackrabbit.version>

		<!-- Properties for Jacoco and Sonar -->
		<coverage.unit.test.path>${project.basedir}/../target/jacoco.exec</coverage.unit.test.path>
		<sonar.core.codeCoveragePlugin>jacoco</sonar.core.codeCoveragePlugin>
		<sonar.dynamicAnalysis>reuseReports</sonar.dynamicAnalysis>
		<sonar.jacoco.reportPath>${coverage.unit.test.path}</sonar.jacoco.reportPath>
		<sonar.language>java</sonar.language>
		<jacoco.version>0.7.1.201405082137</jacoco.version>
	</properties>

	<licenses>
		<license>
			<name>The Apache License, Version 2.0</name>
			<url>http://www.apache.org/licenses/LICENSE-2.0.txt</url>
		</license>
	</licenses>

	<scm>
		<connection>scm:git:git@github.com:moskitoli/scribble.git</connection>
		<developerConnection>scm:git:git@github.com:moskitoli/scribble.git</developerConnection>
		<url>git@github.com:moskitoli/scribble.git</url>
	</scm>

	<developers>
		<developer>
			<name>Gerald Muecke</name>
			<email>gerald@moskito.li</email>
			<organization>Moskito.li</organization>
			<organizationUrl>https://github.com/moskitoli</organizationUrl>
		</developer>
	</developers>

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

	<profiles>
		<profile>
			<id>development</id>
			<activation>
				<activeByDefault>true</activeByDefault>
			</activation>
			<properties>
				<surefireArgLine />
				<tests.json.strict.validation.disabled>false</tests.json.strict.validation.disabled>
			</properties>
		</profile>
		<profile>
			<id>qa</id>
			<properties>
				<tests.json.strict.validation.disabled>true</tests.json.strict.validation.disabled>
			</properties>
			<build>
				<plugins>
					<plugin>
						<groupId>org.jacoco</groupId>
						<artifactId>jacoco-maven-plugin</artifactId>
						<version>${jacoco.version}</version>
						<configuration>
							<skip>${skipTests}</skip>
							<includes>
								<include>li.moskito.scribble.*</include>
							</includes>
						</configuration>
						<executions>
							<execution>
								<id>prepare-agent</id>
								<goals>
									<goal>prepare-agent</goal>
								</goals>
								<configuration>
									<destFile>${coverage.unit.test.path}</destFile>
									<append>true</append>
									<propertyName>surefireArgLine</propertyName>
								</configuration>
							</execution>
						</executions>
					</plugin>
					<plugin>
						<groupId>org.codehaus.mojo</groupId>
						<artifactId>sonar-maven-plugin</artifactId>
						<version>2.4</version>
					</plugin>
				</plugins>
			</build>
		</profile>
		<profile>
			<id>release</id>
			<properties>
				<surefireArgLine />
			</properties>
			<build>
				<plugins>
					<plugin>
						<groupId>org.apache.maven.plugins</groupId>
						<artifactId>maven-source-plugin</artifactId>
						<version>2.2.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.1</version>
						<executions>
							<execution>
								<id>attach-javadocs</id>
								<goals>
									<goal>jar</goal>
								</goals>
							</execution>
						</executions>
						<configuration>
							<additionalJOptions>
								<additionalJOption>-J-Xmx16m </additionalJOption>
							</additionalJOptions>
						</configuration>
					</plugin>
					<plugin>
						<groupId>org.apache.maven.plugins</groupId>
						<artifactId>maven-gpg-plugin</artifactId>
						<version>1.5</version>
						<executions>
							<execution>
								<id>sign-artifacts</id>
								<phase>verify</phase>
								<goals>
									<goal>sign</goal>
								</goals>
							</execution>
						</executions>
					</plugin>
					<plugin>
						<groupId>external.atlassian.jgitflow</groupId>
						<artifactId>jgitflow-maven-plugin</artifactId>
						<version>1.0-m4.3</version>
						<configuration>
							<enableSshAgent>false</enableSshAgent>
							<autoVersionSubmodules>true</autoVersionSubmodules>
							<pushFeatures>true</pushFeatures>
							<pushReleases>true</pushReleases>
							<pushHotfixes>true</pushHotfixes>
							<noDeploy>false</noDeploy>
							<alwaysUpdateOrigin>true</alwaysUpdateOrigin>
							<flowInitContext>
								<developBranchName>development</developBranchName>
								<versionTagPrefix>rev-</versionTagPrefix>
							</flowInitContext>
						</configuration>
					</plugin>
					<plugin>
						<groupId>org.sonatype.plugins</groupId>
						<artifactId>nexus-staging-maven-plugin</artifactId>
						<version>1.6.5</version>
						<extensions>true</extensions>
						<configuration>
							<serverId>ossrh</serverId>
							<nexusUrl>https://oss.sonatype.org/</nexusUrl>
							<autoReleaseAfterClose>true</autoReleaseAfterClose>
						</configuration>
					</plugin>
				</plugins>
			</build>
		</profile>
	</profiles>


	<dependencies>
	    <!-- JEE 7 -->
		<dependency>
			<groupId>javax</groupId>
			<artifactId>javaee-api</artifactId>
			<version>${javax.javaee-api.version}</version>
		</dependency>
		<dependency>
			<groupId>org.jacoco</groupId>
			<artifactId>jacoco-maven-plugin</artifactId>
			<version>${jacoco.version}</version>
			<scope>provided</scope>
		</dependency>
		<dependency>
			<groupId>org.slf4j</groupId>
			<artifactId>slf4j-api</artifactId>
			<version>${slf4j.version}</version>
		</dependency>
		<!-- Binding for Log4J -->
		<dependency>
			<groupId>org.apache.logging.log4j</groupId>
			<artifactId>log4j-slf4j-impl</artifactId>
			<version>${log4j.version}</version>
		</dependency>
		<!-- Log4j API and Core implementation required for binding -->
		<dependency>
			<groupId>org.apache.logging.log4j</groupId>
			<artifactId>log4j-api</artifactId>
			<version>${log4j.version}</version>
		</dependency>
		<dependency>
			<groupId>org.apache.logging.log4j</groupId>
			<artifactId>log4j-core</artifactId>
			<version>${log4j.version}</version>
		</dependency>
		<!-- Apache Commons -->
		<dependency>
			<groupId>commons-io</groupId>
			<artifactId>commons-io</artifactId>
			<version>${apache.commons.io.version}</version>
		</dependency>
		<!-- Test libraries -->
		<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>
		<!-- Apache Deltaspike -->
		<dependency>
			<groupId>org.apache.deltaspike.core</groupId>
			<artifactId>deltaspike-core-api</artifactId>
			<version>${apache.deltaspike.version}</version>
		</dependency>
		<dependency>
			<groupId>org.apache.deltaspike.core</groupId>
			<artifactId>deltaspike-core-impl</artifactId>
			<version>${apache.deltaspike.version}</version>
		</dependency>
		<!-- JCR Dependencies -->
		<dependency>
			<groupId>javax.jcr</groupId>
			<artifactId>jcr</artifactId>
			<version>${javax.jcr.version}</version>
		</dependency>
		<!-- Apache Jackrabbit -->
		<dependency>
			<groupId>org.apache.jackrabbit</groupId>
			<artifactId>jackrabbit-core</artifactId>
			<version>${apache.jackrabbit.version}</version>
			<scope>provided</scope>
		</dependency>
		<dependency>
			<groupId>org.apache.jackrabbit</groupId>
			<artifactId>jackrabbit-jcr-commons</artifactId>
			<version>${apache.jackrabbit.version}</version>
			<scope>provided</scope>
		</dependency>
	</dependencies>

	<build>
		<plugins>
			<plugin>
				<groupId>org.apache.maven.plugins</groupId>
				<artifactId>maven-compiler-plugin</artifactId>
				<version>3.1</version>
				<configuration>
					<source>1.7</source>
					<target>1.7</target>
					<compilerVersion>1.7</compilerVersion>
				</configuration>
			</plugin>

			<plugin>
				<groupId>org.apache.maven.plugins</groupId>
				<artifactId>maven-surefire-plugin</artifactId>
				<version>2.17</version>
				<configuration>
					<forkCount>1</forkCount>
					<reuseForks>false</reuseForks>
					<runOrder>random</runOrder>
					<enableAssertions>true</enableAssertions>
					<argLine>-Xms16M -Xmx512M ${surefireArgLine}</argLine>
					<systemPropertyVariables>
						<tests.json.strict.validation.disabled>${tests.json.strict.validation.disabled}</tests.json.strict.validation.disabled>
					</systemPropertyVariables>
				</configuration>
			</plugin>
		</plugins>
	</build>

</project>