<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>
	<artifactId>afterburner-library</artifactId>
	<name>Afterburner Library</name>
	<description>A library to help other librairies getting rid of boiler plate via byte code manipulation. Works on Android too.</description>

	<parent>
		<groupId>com.github.stephanenicolas.afterburner</groupId>
		<artifactId>afterburner-parent</artifactId>
		<version>1.0.2</version>
	</parent>

	<properties>
		<java.version>1.6</java.version>

		<!--PLUGINS -->
		<maven-jar-plugin.version>2.4</maven-jar-plugin.version>
		<maven-source-plugin.version>2.2</maven-source-plugin.version>
		<maven-javadoc-plugin.version>2.8</maven-javadoc-plugin.version>
		<maven-compiler-plugin.version>2.5.1</maven-compiler-plugin.version>
		<maven-checkstyle-plugin.version>2.11</maven-checkstyle-plugin.version>
		<findbugs-maven-plugin.version>2.5.3</findbugs-maven-plugin.version>
		<eclipse-lifecycle-plugin.version>1.0.0</eclipse-lifecycle-plugin.version>
		<jacoco-maven-plugin.version>0.7.1.201405082137</jacoco-maven-plugin.version>
		<coveralls-maven-plugin.version>2.2.0</coveralls-maven-plugin.version>

		<!--LIBRARIES -->
		<android-map.version>7_r1</android-map.version>
		<android-support-v4.version>19</android-support-v4.version>
		<android-appcompat-v7.version>19</android-appcompat-v7.version>
		<actionbarsherlock.version>4.2.0</actionbarsherlock.version>
		<jsr305.version>2.0.3</jsr305.version>
		<findbugs-annotations.version>1.0.0</findbugs-annotations.version>
		<guice.version>3.0</guice.version>
		<lombok.version>1.14.2</lombok.version>
		<javassist.version>3.18.1-GA</javassist.version>
		<slf4j.version>1.7.7</slf4j.version>

		<!--TESTING -->
		<easymock.version>3.2</easymock.version>
		<junit.version>4.11</junit.version>
	</properties>

	<dependencies>
		<!-- TEST DEPENDENCIES -->
		<!-- http://stackoverflow.com/a/18463743/693752 -->
		<dependency>
			<groupId>junit</groupId>
			<artifactId>junit</artifactId>
			<version>${junit.version}</version>
			<scope>test</scope>
		</dependency>

		<!-- DEPENDENCIES -->
		<dependency>
			<groupId>org.javassist</groupId>
			<artifactId>javassist</artifactId>
			<version>${javassist.version}</version>
		</dependency>
		<dependency>
			<groupId>org.slf4j</groupId>
			<artifactId>slf4j-api</artifactId>
			<version>${slf4j.version}</version>
		</dependency>
		<dependency>
			<groupId>com.google.code.findbugs</groupId>
			<artifactId>jsr305</artifactId>
			<version>${jsr305.version}</version>
			<scope>test</scope>
		</dependency>
		<dependency>
			<groupId>findbugs</groupId>
			<artifactId>annotations</artifactId>
			<version>${findbugs-annotations.version}</version>
			<type>jar</type>
		</dependency>
		<dependency>
			<groupId>com.google.inject</groupId>
			<artifactId>guice</artifactId>
			<version>${guice.version}</version>
			<classifier>no_aop</classifier>
		</dependency>
		<dependency>
			<groupId>org.projectlombok</groupId>
			<artifactId>lombok</artifactId>
			<version>${lombok.version}</version>
			<scope>provided</scope>
		</dependency>

		<!-- TEST DEPENDENCIES -->
		<dependency>
			<groupId>org.easymock</groupId>
			<artifactId>easymock</artifactId>
			<version>${easymock.version}</version>
			<scope>test</scope>
		</dependency>
	</dependencies>

	<build>
		<defaultGoal>package</defaultGoal>
		<plugins>
			<plugin>
				<groupId>org.apache.maven.plugins</groupId>
				<artifactId>maven-compiler-plugin</artifactId>
			</plugin>
			<plugin>
				<groupId>org.apache.maven.plugins</groupId>
				<artifactId>maven-jar-plugin</artifactId>
			</plugin>
			<plugin>
				<groupId>org.apache.maven.plugins</groupId>
				<artifactId>maven-release-plugin</artifactId>
			</plugin>
			<plugin>
				<groupId>org.apache.maven.plugins</groupId>
				<artifactId>maven-source-plugin</artifactId>
			</plugin>
			<plugin>
				<groupId>org.apache.maven.plugins</groupId>
				<artifactId>maven-checkstyle-plugin</artifactId>
			</plugin>
			<plugin>
				<groupId>org.codehaus.mojo</groupId>
				<artifactId>findbugs-maven-plugin</artifactId>
			</plugin>
		</plugins>
	</build>

	<reporting>
		<plugins>
			<plugin>
				<groupId>org.apache.maven.plugins</groupId>
				<artifactId>maven-javadoc-plugin</artifactId>
				<version>${maven-javadoc-plugin.version}</version>
				<configuration>
					<reportOutputDirectory>docs</reportOutputDirectory>
					<destDir>apidocs</destDir>
					<notimestamp>true</notimestamp>
				</configuration>
			</plugin>
		</plugins>
	</reporting>

	<profiles>
		<profile>
			<id>coverage</id>
			<build>
				<plugins>
					<!-- CODE COVERAGE FOR UNIT-TESTS http://www.javacodegeeks.com/2013/08/creating-code-coverage-reports-for-unit-and-integration-tests-with-the-jacoco-maven-plugin.html -->
					<plugin>
						<groupId>org.jacoco</groupId>
						<artifactId>jacoco-maven-plugin</artifactId>
						<version>${jacoco-maven-plugin.version}</version>
						<configuration>
							<excludes>
								<exclude>**/*Exception.class</exclude>
							</excludes>
						</configuration>
						<executions>
							<!-- Prepares the property pointing to the JaCoCo runtime agent which 
								is passed as VM argument when Maven the Surefire plugin is executed. -->
							<execution>
								<id>pre-unit-test</id>
								<goals>
									<goal>prepare-agent</goal>
								</goals>
								<configuration>
									<!-- Sets the path to the file which contains the execution data. -->
									<destFile>${project.build.directory}/coverage-reports/jacoco-ut.exec</destFile>
								</configuration>
							</execution>
							<!-- Ensures that the code coverage report for unit tests is created 
								after unit tests have been run. -->
							<execution>
								<id>post-unit-test</id>
								<phase>test</phase>
								<goals>
									<goal>report</goal>
								</goals>
								<configuration>
									<!-- Sets the path to the file which contains the execution data. -->
									<dataFile>${project.build.directory}/coverage-reports/jacoco-ut.exec</dataFile>
									<!-- Sets the output directory for the code coverage report. -->
									<outputDirectory>${project.reporting.outputDirectory}/jacoco-ut</outputDirectory>
								</configuration>
							</execution>
						</executions>
					</plugin>
					<plugin>
						<groupId>org.eluder.coveralls</groupId>
						<artifactId>coveralls-maven-plugin</artifactId>
						<version>${coveralls-maven-plugin.version}</version>
						<executions>
							<execution>
								<id>post-unit-test</id>
								<phase>test</phase>
								<goals>
									<goal>jacoco</goal>
								</goals>
								<configuration>
									<coverageFile>${project.reporting.outputDirectory}/jacoco-ut/jacoco.xml</coverageFile>
								</configuration>
							</execution>
						</executions>
					</plugin>
				</plugins>
			</build>
		</profile>
	</profiles>

</project>
