<?xml version="1.0"?>
<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">
  <parent>
    <artifactId>openimaj-hadoop-tools</artifactId>
    <groupId>org.openimaj</groupId>
    <version>1.3.6</version>
    <relativePath>../</relativePath>
  </parent>
  <modelVersion>4.0.0</modelVersion>
  <groupId>org.openimaj.tools</groupId>
  <artifactId>SequenceFileTool</artifactId>
  <packaging>jar</packaging>
  <name>SequenceFileTool</name>
  <inceptionYear>2011</inceptionYear>
  <description>
		Tool for building, inspecting and extracting Hadoop SequenceFiles.
    </description>
  <properties>
    <project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
  </properties>
  <dependencies>
    <dependency>
      <groupId>org.openimaj</groupId>
      <artifactId>core-hadoop</artifactId>
      <version>1.3.6</version>
      <scope>compile</scope>
    </dependency>
		<dependency>
			<groupId>org.apache.hadoop</groupId>
			<artifactId>hadoop-hdfs</artifactId>
			<version>2.0.0-cdh4.7.0</version>
		</dependency>
    <dependency>
      <groupId>org.openimaj</groupId>
      <artifactId>test-resources</artifactId>
      <version>1.3.6</version>
      <scope>test</scope>
    </dependency>
    <dependency>
      <groupId>org.openimaj</groupId>
      <artifactId>ImprovedArgs4J</artifactId>
      <version>1.3.6</version>
      <scope>compile</scope>
    </dependency>
    <dependency>
      <groupId>junit</groupId>
      <artifactId>junit</artifactId>
      <version>4.8.2</version>
      <scope>test</scope>
    </dependency>
  </dependencies>
  <build>
    <plugins>
      <plugin>
        <artifactId>maven-assembly-plugin</artifactId>
        <version>2.2.1</version>
        <configuration>
          <finalName>SequenceFileTool</finalName>
          <appendAssemblyId>false</appendAssemblyId>
          <descriptorRefs>
            <descriptorRef>jar-with-dependencies</descriptorRef>
          </descriptorRefs>
          <archive>
            <manifest>
              <mainClass>org.openimaj.hadoop.tools.sequencefile.SequenceFileTool</mainClass>
            </manifest>
          </archive>
        </configuration>
      </plugin>
			<plugin>
			    <groupId>org.apache.maven.plugins</groupId>
			    <artifactId>maven-shade-plugin</artifactId>
			    <configuration>
			        <createDependencyReducedPom>true</createDependencyReducedPom>
			    </configuration>
			    <executions>
			        <execution>
			            <phase>package</phase>
			            <goals>
			                <goal>shade</goal>
			            </goals>
			            <configuration>
			                <transformers>
			                    <transformer implementation="org.apache.maven.plugins.shade.resource.ServicesResourceTransformer" />
			                    <transformer implementation="org.apache.maven.plugins.shade.resource.ManifestResourceTransformer">
			                        <mainClass>org.openimaj.hadoop.tools.sequencefile.SequenceFileTool</mainClass>
			                    </transformer>
			                </transformers>
											<shadedArtifactAttached>true</shadedArtifactAttached>
											<finalName>SequenceFileTool</finalName>
			            </configuration>
			        </execution>
			    </executions>
			</plugin>
      <plugin>
        <groupId>com.mycila.maven-license-plugin</groupId>
        <artifactId>maven-license-plugin</artifactId>
        <version>1.9.0</version>
        <configuration>
          <header>src/etc/header.txt</header>
          <strictCheck>true</strictCheck>
          <properties>
            <year>${project.inceptionYear}</year>
          </properties>
          <excludes>
            <exclude>AUTHORS</exclude>
            <exclude>COPYING</exclude>
            <exclude>sfutil</exclude>
          </excludes>
          <mapping>
            <jtemp>JAVADOC_STYLE</jtemp>
          </mapping>
          <useDefaultMapping>true</useDefaultMapping>
        </configuration>
      </plugin>
      <plugin>
        <groupId>org.apache.maven.plugins</groupId>
        <artifactId>maven-surefire-plugin</artifactId>
        <version>2.8.1</version>
        <configuration>
          <argLine>-Xmx1G</argLine>
        </configuration>
      </plugin>
    </plugins>
  </build>
</project>
