<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>net.krotscheck.dfr</groupId>
    <artifactId>data-file-reader</artifactId>
    <version>1.0.8</version>

    <packaging>pom</packaging>
    <name>data-file-reader</name>
    <description>A library which reads and writes table-like streams of rows from common file formats.</description>
    <url>https://github.com/krotscheck/dfr</url>

    <modules>
        <module>data-file-reader-base</module>
        <module>data-file-reader-bson</module>
        <module>data-file-reader-json</module>
        <module>data-file-reader-csv</module>
        <module>data-file-filter-column</module>
        <module>data-file-reader-all</module>
    </modules>

    <profiles>
        <profile>
            <id>release-sign-artifacts</id>
            <activation>
                <property>
                    <name>performRelease</name>
                    <value>true</value>
                </property>
            </activation>
            <build>
                <plugins>
                    <plugin>
                        <groupId>org.apache.maven.plugins</groupId>
                        <artifactId>maven-gpg-plugin</artifactId>
                        <version>1.4</version>
                        <configuration>
                            <passphrase>${gpg.passphrase}</passphrase>
                        </configuration>
                        <executions>
                            <execution>
                                <id>sign-artifacts</id>
                                <phase>verify</phase>
                                <goals>
                                    <goal>sign</goal>
                                </goals>
                            </execution>
                        </executions>
                    </plugin>
                </plugins>
            </build>
        </profile>
    </profiles>

    <!-- The license under which this package is released -->
    <licenses>
        <license>
            <name>Apache License, Version 2.0</name>
            <url>http://www.apache.org/licenses/LICENSE-2.0.txt</url>
            <distribution>repo</distribution>
        </license>
    </licenses>

    <organization>
        <name>krotscheck.net</name>
        <url>http://www.krotscheck.net</url>
    </organization>

    <ciManagement>
        <system>travis</system>
        <url>https://travis-ci.org/krotscheck/data-file-reader</url>
    </ciManagement>

    <issueManagement>
        <system>github</system>
        <url>https://github.com/krotscheck/data-file-reader/issues</url>
    </issueManagement>

    <developers>
        <developer>
            <id>krotscheck</id>
            <name>Michael Krotscheck</name>
            <email>krotscheck@gmail.com</email>
            <url>http://www.krotscheck.net</url>
            <organization>krotscheck.net</organization>
            <organizationUrl>http://www.krotscheck.net</organizationUrl>
            <roles>
                <role>owner</role>
            </roles>
            <timezone>-8</timezone>
            <properties>
                <picUrl>
                    http://www.gravatar.com/avatar/7be4c8b3919835b3d0c256fc3b3e9c55.png
                </picUrl>
            </properties>
        </developer>
    </developers>

    <scm>
        <developerConnection>
            scm:git:git@github.com:krotscheck/data-file-reader.git
        </developerConnection>
        <connection>
            scm:git:git@github.com:krotscheck/data-file-reader.git
        </connection>
        <url>
            https://github.com/krotscheck/data-file-reader
        </url>
        <tag>data-file-reader-1.0.8</tag>
    </scm>

    <properties>
        <jdk.version>1.7</jdk.version>
        <jackson.version>2.4.3</jackson.version>
        <project.build.sourceEncoding>
            UTF-8
        </project.build.sourceEncoding>
        <project.reporting.outputEncoding>
            UTF-8
        </project.reporting.outputEncoding>

        <!-- velocity variables -->
        <site_version>${project.version}</site_version>
    </properties>

    <distributionManagement>
        <site>
            <id>github</id>
            <name>GitHub Sites</name>
            <url>https://krotscheck.github.com/data-file-reader</url>
        </site>
        <snapshotRepository>
            <id>sonatype-nexus-snapshots</id>
            <name>Sonatype Nexus snapshot repository</name>
            <url>https://oss.sonatype.org/content/repositories/snapshots</url>
        </snapshotRepository>
        <repository>
            <id>sonatype-nexus-staging</id>
            <name>Sonatype Nexus release repository</name>
            <url>https://oss.sonatype.org/service/local/staging/deploy/maven2/</url>
        </repository>
    </distributionManagement>

    <build>
        <plugins>
            <!-- Deploy the web site -->
            <plugin>
                <groupId>com.github.github</groupId>
                <artifactId>site-maven-plugin</artifactId>
                <configuration>
                    <server>github</server>
                    <message>Site: ${project.groupId}:${project.artifactId}:${project.version}</message>
                    <merge>true</merge>
                    <oauth2Token>${github.oauth2Token}</oauth2Token>
                </configuration>
            </plugin>

            <plugin>
                <groupId>org.apache.maven.plugins</groupId>
                <artifactId>maven-release-plugin</artifactId>
            </plugin>
        </plugins>

        <pluginManagement>
            <plugins>
                <!-- Release plugin -->
                <plugin>
                    <groupId>org.apache.maven.plugins</groupId>
                    <artifactId>maven-release-plugin</artifactId>
                    <version>2.4.2</version>
                    <dependencies>
                        <dependency>
                            <groupId>org.apache.maven.scm</groupId>
                            <artifactId>maven-scm-provider-gitexe</artifactId>
                            <version>1.9</version>
                        </dependency>
                    </dependencies>
                    <configuration>
                        <arguments>-Dgpg.passphrase=${gpg.passphrase}</arguments>
                    </configuration>
                </plugin>


                <!-- Deploy the web site -->
                <plugin>
                    <groupId>com.github.github</groupId>
                    <artifactId>site-maven-plugin</artifactId>
                    <version>0.10</version>
                    <executions>
                        <execution>
                            <goals>
                                <goal>site</goal>
                            </goals>
                            <phase>site-deploy</phase>
                        </execution>
                    </executions>
                </plugin>

                <!-- Site plugin. -->
                <plugin>
                    <artifactId>maven-site-plugin</artifactId>
                    <version>3.4</version>
                    <configuration>
                        <skipDeploy>true</skipDeploy>
                    </configuration>
                    <dependencies>
                        <dependency>
                            <groupId>lt.velykis.maven.skins</groupId>
                            <artifactId>reflow-velocity-tools</artifactId>
                            <version>1.1.1</version>
                        </dependency>
                        <dependency>
                            <groupId>org.apache.velocity</groupId>
                            <artifactId>velocity</artifactId>
                            <version>1.7</version>
                        </dependency>
                    </dependencies>
                </plugin>

                <!-- Compiler plugin -->
                <plugin>
                    <groupId>org.apache.maven.plugins</groupId>
                    <artifactId>maven-compiler-plugin</artifactId>
                    <version>3.1</version>
                    <configuration>
                        <source>${jdk.version}</source>
                        <target>${jdk.version}</target>
                    </configuration>
                </plugin>

                <!-- Jar configuration -->
                <plugin>
                    <artifactId>maven-jar-plugin</artifactId>
                    <version>2.4</version>
                    <configuration>
                        <archive>
                            <manifest>
                                <addDefaultImplementationEntries>
                                    true
                                </addDefaultImplementationEntries>
                                <addDefaultSpecificationEntries>
                                    true
                                </addDefaultSpecificationEntries>
                            </manifest>
                        </archive>
                    </configuration>
                </plugin>

                <!-- Surefire reporting -->
                <plugin>
                    <groupId>org.apache.maven.plugins</groupId>
                    <artifactId>maven-surefire-plugin</artifactId>
                    <version>2.16</version>
                    <dependencies>
                        <dependency>
                            <groupId>org.apache.maven.surefire</groupId>
                            <artifactId>surefire-junit47</artifactId>
                            <version>2.16</version>
                        </dependency>
                    </dependencies>
                </plugin>

                <!-- Test coverage -->
                <plugin>
                    <groupId>org.codehaus.mojo</groupId>
                    <artifactId>cobertura-maven-plugin</artifactId>
                    <version>2.6</version>
                    <executions>
                        <execution>
                            <goals>
                                <goal>clean</goal>
                                <goal>check</goal>
                            </goals>
                        </execution>
                    </executions>
                    <configuration>
                        <check>
                            <haltOnFailure>true</haltOnFailure>
                            <branchRate>100</branchRate>
                            <lineRate>100</lineRate>
                            <totalBranchRate>100</totalBranchRate>
                            <totalLineRate>100</totalLineRate>
                            <packageLineRate>100</packageLineRate>
                            <packageBranchRate>100</packageBranchRate>
                        </check>
                        <formats>
                            <format>xml</format>
                        </formats>
                    </configuration>
                </plugin>

                <!-- Attach sources -->
                <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</goal>
                            </goals>
                        </execution>
                    </executions>
                </plugin>

                <!-- Attach javadocs -->
                <plugin>
                    <groupId>org.apache.maven.plugins</groupId>
                    <artifactId>maven-javadoc-plugin</artifactId>
                    <version>2.9.1</version>
                    <executions>
                        <execution>
                            <id>attach-javadocs</id>
                            <goals>
                                <goal>jar</goal>
                            </goals>
                        </execution>
                    </executions>
                </plugin>

                <!-- Clean Plugin -->
                <plugin>
                    <artifactId>maven-clean-plugin</artifactId>
                    <version>2.5</version>
                </plugin>

                <!-- Resources plugin -->
                <plugin>
                    <artifactId>maven-resources-plugin</artifactId>
                    <version>2.6</version>
                </plugin>

                <!-- Install plugin -->
                <plugin>
                    <artifactId>maven-install-plugin</artifactId>
                    <version>2.5.1</version>
                </plugin>

                <!-- Deploy plugin  -->
                <plugin>
                    <artifactId>maven-deploy-plugin</artifactId>
                    <version>2.8.1</version>
                </plugin>

                <!-- Dependency plugin -->
                <plugin>
                    <artifactId>maven-dependency-plugin</artifactId>
                    <version>2.8</version>
                </plugin>

                <!-- Checkstyle -->
                <plugin>
                    <groupId>org.apache.maven.plugins</groupId>
                    <artifactId>maven-checkstyle-plugin</artifactId>
                    <version>2.13</version>
                </plugin>

            </plugins>
        </pluginManagement>
    </build>

    <dependencies>

        <!-- Logging Framework -->
        <dependency>
            <groupId>org.slf4j</groupId>
            <artifactId>slf4j-api</artifactId>
            <version>1.7.5</version>
        </dependency>
        <dependency>
            <groupId>ch.qos.logback</groupId>
            <artifactId>logback-core</artifactId>
            <version>1.0.13</version>
            <scope>test</scope>
        </dependency>

        <!-- JUnit -->
        <dependency>
            <groupId>junit</groupId>
            <artifactId>junit</artifactId>
            <version>4.11</version>
            <scope>test</scope>
        </dependency>
        <dependency>
            <groupId>org.mockito</groupId>
            <artifactId>mockito-all</artifactId>
            <version>1.9.5</version>
            <scope>test</scope>
        </dependency>
        <dependency>
            <groupId>org.powermock</groupId>
            <artifactId>powermock-module-junit4</artifactId>
            <version>1.5.5</version>
            <scope>test</scope>
        </dependency>
        <dependency>
            <groupId>org.powermock</groupId>
            <artifactId>powermock-api-mockito</artifactId>
            <version>1.5.5</version>
            <scope>test</scope>
        </dependency>

        <dependency>
            <groupId>net.krotscheck</groupId>
            <artifactId>knet-utils</artifactId>
            <version>1.0.1</version>
        </dependency>
    </dependencies>

    <reporting>
        <plugins>
            <plugin>
                <groupId>org.apache.maven.plugins</groupId>
                <artifactId>maven-project-info-reports-plugin</artifactId>
                <version>2.7</version>
                <configuration>
                    <dependencyLocationsEnabled>false</dependencyLocationsEnabled>
                    <anonymousConnection>
                        scm:git:git@github.com:krotscheck/data-file-reader.git
                    </anonymousConnection>
                    <developerConnection>
                        scm:git:git@github.com:krotscheck/data-file-reader.git
                    </developerConnection>
                </configuration>
                <reportSets>
                    <reportSet>
                        <reports>
                            <report>summary</report>
                            <report>license</report>
                            <report>modules</report>
                            <report>project-team</report>
                            <report>dependencies</report>
                            <report>dependency-convergence</report>
                            <report>plugins</report>
                        </reports>
                    </reportSet>
                </reportSets>
            </plugin>
            <plugin>
                <groupId>org.apache.maven.plugins</groupId>
                <artifactId>maven-jxr-plugin</artifactId>
                <version>2.3</version>
            </plugin>
            <plugin>
                <groupId>org.codehaus.mojo</groupId>
                <artifactId>findbugs-maven-plugin</artifactId>
                <version>3.0.0</version>
                <configuration>
                    <xmlOutput>true</xmlOutput>
                    <xmlOutputDirectory>target/site</xmlOutputDirectory>
                </configuration>
            </plugin>
            <plugin>
                <groupId>org.apache.maven.plugins</groupId>
                <artifactId>maven-checkstyle-plugin</artifactId>
                <configuration>
                    <configLocation>checkstyle.xml</configLocation>
                    <failsOnError>true</failsOnError>
                </configuration>
            </plugin>
            <plugin>
                <groupId>org.apache.maven.plugins</groupId>
                <artifactId>maven-surefire-report-plugin</artifactId>
                <version>2.17</version>
            </plugin>
            <plugin>
                <groupId>org.codehaus.mojo</groupId>
                <artifactId>cobertura-maven-plugin</artifactId>
            </plugin>
            <plugin>
                <groupId>org.apache.maven.plugins</groupId>
                <artifactId>maven-javadoc-plugin</artifactId>
                <version>2.9.1</version>
            </plugin>
        </plugins>
    </reporting>
</project>
