<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>com.kryshchuk</groupId>
  <artifactId>parent</artifactId>
  <version>1.2.5</version>
  <packaging>pom</packaging>

  <name>Parent POM</name>

  <description>Contains defaults and common behavior for all projects.</description>

  <url>http://ykryshchuk.github.com/parent/</url>

  <inceptionYear>2013</inceptionYear>

  <scm>
    <connection>scm:git:git://github.com/ykryshchuk/parent.git</connection>
    <developerConnection>scm:git:git@github.com:ykryshchuk/parent.git</developerConnection>
    <url>git@github.com:ykryshchuk/parent.git</url>
    <tag>parent-1.2.5</tag>
  </scm>

  <licenses>

    <license>
      <name>GNU GENERAL PUBLIC LICENSE</name>
      <url>http://www.gnu.org/licenses/gpl.html</url>
      <distribution>repo</distribution>
    </license>

  </licenses>

  <organization>
    <name>KOrga</name>
    <url>https://kryshchuk.com/</url>
  </organization>

  <developers>

    <developer>
      <id>ykryshchuk</id>
      <email>yuriy.kryshchuk@gmail.com</email>
      <name>Yuriy Kryshchuk</name>
      <timezone>2</timezone>
      <organization>KOrga</organization>
      <roles>
        <role>Developer</role>
      </roles>
    </developer>

  </developers>

  <distributionManagement>

    <snapshotRepository>
      <id>sonatype-nexus-snapshots</id>
      <name>Sonatype Nexus Snapshots</name>
      <url>https://oss.sonatype.org/content/repositories/snapshots/</url>
    </snapshotRepository>

    <repository>
      <id>sonatype-nexus-staging</id>
      <name>Nexus Release Repository</name>
      <url>https://oss.sonatype.org/service/local/staging/deploy/maven2/</url>
    </repository>

  </distributionManagement>

  <build>

    <pluginManagement>

      <plugins>

        <plugin>
          <artifactId>maven-gpg-plugin</artifactId>
          <version>1.4</version>
        </plugin>

        <plugin>
          <artifactId>maven-javadoc-plugin</artifactId>
          <version>2.9</version>
        </plugin>

        <plugin>
          <artifactId>maven-deploy-plugin</artifactId>
          <version>2.7</version>
        </plugin>

        <plugin>
          <artifactId>maven-source-plugin</artifactId>
          <version>2.2.1</version>
        </plugin>

        <plugin>
          <artifactId>maven-project-info-reports-plugin</artifactId>
          <version>2.6</version>
        </plugin>

        <plugin>
          <artifactId>maven-jar-plugin</artifactId>
          <version>2.4</version>
        </plugin>
        
        <plugin>
          <artifactId>maven-dependency-plugin</artifactId>
          <version>2.7</version>
        </plugin>
        
        <plugin>
          <artifactId>maven-resources-plugin</artifactId>
          <version>2.6</version>
        </plugin>
        
        <plugin>
          <artifactId>maven-release-plugin</artifactId>
          <version>2.4</version>
        </plugin>

        <plugin>
          <artifactId>maven-surefire-plugin</artifactId>
          <version>2.14</version>
        </plugin>

        <plugin>
          <artifactId>maven-scm-plugin</artifactId>
          <version>1.8.1</version>
        </plugin>

        <plugin>
          <artifactId>maven-invoker-plugin</artifactId>
          <version>1.8</version>
        </plugin>

        <plugin>
          <artifactId>maven-compiler-plugin</artifactId>
          <version>3.0</version>
          <configuration>
            <source>1.7</source>
            <target>1.7</target>
          </configuration>
        </plugin>

        <plugin>
          <artifactId>maven-site-plugin</artifactId>
          <version>3.2</version>
          <configuration>
            <reportPlugins>
              <plugin>
                <artifactId>maven-project-info-reports-plugin</artifactId>
                <configuration>
                  <dependencyDetailsEnabled>false</dependencyDetailsEnabled>
                  <dependencyLocationsEnabled>false</dependencyLocationsEnabled>
                  <showAvatarImages>true</showAvatarImages>
                  <linkOnly>true</linkOnly>
                </configuration>
                <reports>
                  <report>summary</report>
                  <report>license</report>
                  <report>scm</report>
                  <report>project-team</report>
                  <report>dependencies</report>
                </reports>
              </plugin>
            </reportPlugins>
          </configuration>
          <executions>
            <execution>
              <id>attach-descriptor</id>
              <goals>
                <goal>attach-descriptor</goal>
              </goals>
            </execution>
          </executions>
        </plugin>

        <plugin>
          <groupId>org.eclipse.m2e</groupId>
          <artifactId>lifecycle-mapping</artifactId>
          <version>1.0.0</version>
          <configuration>
            <lifecycleMappingMetadata>
              <pluginExecutions combine.children="append"> </pluginExecutions>
            </lifecycleMappingMetadata>
          </configuration>
        </plugin>

      </plugins>

    </pluginManagement>

  </build>

  <profiles>

    <profile>
      <id>GPG</id>
      <build>
        <plugins>
          <plugin>
            <artifactId>maven-release-plugin</artifactId>
            <configuration>
              <arguments>-Dgpg.passphrase=${gpg.passphrase}</arguments>
            </configuration>
          </plugin>
          <plugin>
            <artifactId>maven-gpg-plugin</artifactId>
            <executions>
              <execution>
                <id>sign-artifacts</id>
                <phase>verify</phase>
                <goals>
                  <goal>sign</goal>
                </goals>
              </execution>
            </executions>
          </plugin>
        </plugins>
      </build>
    </profile>

    <profile>
      <id>OSS</id>
      <pluginRepositories>
        <pluginRepository>
          <id>public.oss.sonatype.org</id>
          <name>Sonatype Staging Repository</name>
          <url>https://oss.sonatype.org/content/groups/staging/</url>
          <releases>
            <enabled>true</enabled>
          </releases>
          <snapshots>
            <enabled>false</enabled>
          </snapshots>
        </pluginRepository>
      </pluginRepositories>
      <repositories>
        <repository>
          <id>public.oss.sonatype.org</id>
          <name>Sonatype Staging Repository</name>
          <url>https://oss.sonatype.org/content/groups/staging/</url>
          <releases>
            <enabled>true</enabled>
          </releases>
          <snapshots>
            <enabled>false</enabled>
          </snapshots>
        </repository>
      </repositories>
    </profile>

    <profile>
      <id>BuildHive</id>
      <build>
        <pluginManagement>
          <plugins>
            <plugin>
              <artifactId>maven-compiler-plugin</artifactId>
              <configuration>
                <executable>${jvm.home}/bin/javac</executable>
                <fork>true</fork>
              </configuration>
            </plugin>
            <plugin>
              <artifactId>maven-surefire-plugin</artifactId>
              <configuration>
                <jvm>${jvm.home}/bin/java</jvm>
                <forkMode>once</forkMode>
              </configuration>
            </plugin>
          </plugins>
        </pluginManagement>
      </build>
      <properties>
        <jvm.home>/opt/jdk/jdk1.7.0</jvm.home>
        <invoker.javaHome>${jvm.home}</invoker.javaHome>
      </properties>
    </profile>

    <profile>
      <id>FixSource</id>
      <build>
        <pluginManagement>
          <plugins>
            <plugin>
              <groupId>com.kryshchuk.maven.plugins</groupId>
              <artifactId>fixsource-maven-plugin</artifactId>
              <version>1.1.3</version>
            </plugin>
          </plugins>
        </pluginManagement>
        <plugins>
          <plugin>
            <groupId>com.kryshchuk.maven.plugins</groupId>
            <artifactId>fixsource-maven-plugin</artifactId>
            <configuration>
              <header><![CDATA[
              ${project.name}
              Copyright (C) 2013  Yuriy Kryshchuk
              
              This program is free software: you can redistribute it and/or modify
              it under the terms of the GNU General Public License as published by
              the Free Software Foundation, either version 3 of the License, or
              (at your option) any later version.
              
              This program 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 General Public License for more details.
              
              You should have received a copy of the GNU General Public License
              along with this program.  If not, see <http://www.gnu.org/licenses />.              
              ]]></header>
            </configuration>
            <executions>
              <execution>
                <id>fix-java-sources</id>
                <phase>process-sources</phase>
                <goals>
                  <goal>fix-java</goal>
                </goals>
              </execution>
              <execution>
                <id>fix-test-java-sources</id>
                <phase>process-test-sources</phase>
                <goals>
                  <goal>fix-test-java</goal>
                </goals>
              </execution>
            </executions>
          </plugin>
          <plugin>
            <groupId>org.eclipse.m2e</groupId>
            <artifactId>lifecycle-mapping</artifactId>
            <configuration>
              <lifecycleMappingMetadata>
                <pluginExecutions combine.children="append">
                  <pluginExecution>
                    <pluginExecutionFilter>
                      <groupId>com.kryshchuk.maven.plugins</groupId>
                      <artifactId>fixsource-maven-plugin</artifactId>
                      <versionRange>[1.0,)</versionRange>
                      <goals>
                        <goal>fix-java</goal>
                        <goal>fix-test-java</goal>
                        <goal>fix-xml</goal>
                      </goals>
                    </pluginExecutionFilter>
                    <action>
                      <ignore />
                    </action>
                  </pluginExecution>
                </pluginExecutions>
              </lifecycleMappingMetadata>
            </configuration>
          </plugin>
        </plugins>
      </build>
    </profile>

  </profiles>

  <dependencyManagement>

    <dependencies>

      <dependency>
        <groupId>org.mockito</groupId>
        <artifactId>mockito-all</artifactId>
        <version>1.9.5</version>
      </dependency>

      <dependency>
        <groupId>org.testng</groupId>
        <artifactId>testng</artifactId>
        <version>6.8</version>
      </dependency>

      <dependency>
        <groupId>org.slf4j</groupId>
        <artifactId>slf4j-api</artifactId>
        <version>1.7.4</version>
      </dependency>

      <dependency>
        <groupId>ch.qos.logback</groupId>
        <artifactId>logback-classic</artifactId>
        <version>1.0.10</version>
      </dependency>
      
    </dependencies>

  </dependencyManagement>

  <dependencies>

    <dependency>
      <groupId>org.mockito</groupId>
      <artifactId>mockito-all</artifactId>
      <scope>test</scope>
    </dependency>

    <dependency>
      <groupId>org.testng</groupId>
      <artifactId>testng</artifactId>
      <scope>test</scope>
    </dependency>

    <dependency>
      <groupId>ch.qos.logback</groupId>
      <artifactId>logback-classic</artifactId>
      <scope>test</scope>
    </dependency>
    
  </dependencies>

  <properties>
    <project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
    <project.reporting.outputEncoding>UTF-8</project.reporting.outputEncoding>
    <project.siteUrl>${local.sites}/${project.artifactId}</project.siteUrl>
  </properties>

</project>
