<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>info.freelibrary</groupId>
  <artifactId>llp2jlp-maven-plugin</artifactId>
  <version>0.0.3</version>
  <packaging>maven-plugin</packaging>

  <name>llp2jlp Maven Plugin</name>
  <url>http://projects.freelibrary.info/llp2jlp-maven-plugin</url>

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

  <scm>
    <connection>scm:git:git@github.com:ksclarke/llp2jlp-maven-plugin.git</connection>
    <developerConnection>scm:git:git@github.com:ksclarke/llp2jlp-maven-plugin.git</developerConnection>
    <url>git@github.com:ksclarke/llp2jlp-maven-plugin.git</url>
  </scm>

  <issueManagement>
    <system>GitHub</system>
    <url>https://github.com/ksclarke/llp2jlp-maven-plugin/issues</url>
  </issueManagement>

  <organization>
    <name>FreeLibrary</name>
    <url>http://freelibrary.info</url>
  </organization>

  <developers>
    <!-- developers are actively contributing code and will field questions -->
    <developer>
      <email>ksclarke@gmail.com</email>
      <name>Kevin S. Clarke</name>
      <url>http://kevinclarke.info</url>
      <roles>
        <role>developer</role>
      </roles>
      <timezone>America/New_York</timezone>
    </developer>
  </developers>

  <properties>
    <project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
    <project.reporting.outputEncoding>UTF-8</project.reporting.outputEncoding>
  </properties>

  <dependencies>
    <dependency>
      <groupId>org.apache.maven</groupId>
      <artifactId>maven-plugin-api</artifactId>
      <version>3.1.0</version>
    </dependency>
    <dependency>
      <groupId>org.apache.maven</groupId>
      <artifactId>maven-project</artifactId>
      <version>2.2.1</version>
    </dependency>
    <dependency>
      <!-- findbugs wants this or it complains -->
      <groupId>org.apache.maven</groupId>
      <artifactId>maven-artifact</artifactId>
      <version>2.2.1</version>
    </dependency>    
    <dependency>
      <groupId>org.apache.maven.plugin-tools</groupId>
      <artifactId>maven-plugin-annotations</artifactId>
      <version>3.2</version>
    </dependency>
    <dependency>
      <groupId>info.freelibrary</groupId>
      <artifactId>freelib-utils</artifactId>
      <version>0.3.0</version>
    </dependency>
  </dependencies>

  <build>
    <plugins>
      <!-- copies documentation that will be used in the public project site -->
      <plugin>
        <groupId>org.apache.maven.plugins</groupId>
        <artifactId>maven-resources-plugin</artifactId>
        <version>2.6</version>
        <configuration>
          <encoding>${project.build.sourceEncoding}</encoding>
        </configuration>
        <executions>
          <execution>
            <id>copy-resources</id>
            <phase>validate</phase>
            <goals>
              <goal>copy-resources</goal>
            </goals>
            <configuration>
              <outputDirectory>${basedir}/target/site</outputDirectory>
              <resources>
                <resource>
                  <directory>src/site/resources/eclipse</directory>
                </resource>
                <resource>
                  <directory>src/site/resources/checkstyle</directory>
                </resource>
              </resources>
            </configuration>
          </execution>
        </executions>
      </plugin>
      <plugin>
        <groupId>org.apache.maven.plugins</groupId>
        <artifactId>maven-compiler-plugin</artifactId>
        <version>2.5.1</version>
      </plugin>
      <plugin>
        <groupId>org.apache.maven.plugins</groupId>
        <artifactId>maven-plugin-plugin</artifactId>
        <version>3.2</version>
        <configuration>
          <skipErrorNoDescriptorsFound>true</skipErrorNoDescriptorsFound>
        </configuration>
        <executions>
          <execution>
            <id>mojo-descriptor</id>
            <goals>
              <goal>descriptor</goal>
            </goals>
          </execution>
          <execution>
            <id>help-goal</id>
            <goals>
              <goal>helpmojo</goal>
            </goals>
          </execution>
        </executions>
      </plugin>
      <!-- generates javadocs -->
      <plugin>
        <groupId>org.apache.maven.plugins</groupId>
        <artifactId>maven-javadoc-plugin</artifactId>
        <version>2.9</version>
        <configuration>
          <charset>${project.build.sourceEncoding}</charset>
          <docencoding>${project.build.sourceEncoding}</docencoding>
          <docfilessubdirs>true</docfilessubdirs>
          <links>
            <link>http://download.oracle.com/javase/7/docs/api/</link>
            <link>http://maven.apache.org/ref/3.1.0/apidocs/</link>
          </links>
          <notimestamp>true</notimestamp>
          <show>protected</show>
          <source>1.7</source>
        </configuration>
      </plugin>
      <!-- maven site generates documentation for use in project website -->
      <plugin>
        <groupId>org.apache.maven.plugins</groupId>
        <artifactId>maven-site-plugin</artifactId>
        <version>3.3</version>
        <configuration>
          <generateReports>true</generateReports>
          <inputEncoding>${project.build.sourceEncoding}</inputEncoding>
          <outputEncoding>${project.build.sourceEncoding}</outputEncoding>
          <reportPlugins>
            <plugin>
              <groupId>org.apache.maven.plugins</groupId>
              <artifactId>maven-jxr-plugin</artifactId>
              <version>2.3</version>
              <configuration>
                <aggregate>true</aggregate>
              </configuration>
            </plugin>
            <plugin>
              <groupId>org.codehaus.mojo</groupId>
              <artifactId>jdepend-maven-plugin</artifactId>
            </plugin>
            <plugin>
              <groupId>org.apache.maven.plugins</groupId>
              <artifactId>maven-project-info-reports-plugin</artifactId>
              <version>2.6</version>
              <configuration>
                <anonymousConnection>scm:git:git@github.com:ksclarke/llp2jlp-maven-plugin.git</anonymousConnection>
                <developerConnection>scm:git:git@github.com:ksclarke/llp2jlp-maven-plugin.git</developerConnection>
              </configuration>
              <reportSets>
                <reportSet>
                  <reports>
                    <report>summary</report>
                    <report>license</report>
                    <report>modules</report>
                    <report>project-team</report>
                    <report>plugins</report>
                    <report>dependency-info</report>
                  </reports>
                </reportSet>
              </reportSets>
            </plugin>
            <plugin>
              <groupId>org.apache.maven.plugins</groupId>
              <artifactId>maven-surefire-plugin</artifactId>
              <version>2.15</version>
              <configuration>
                <forkCount>3</forkCount>
                <reuseForks>true</reuseForks>
                <argLine>-XX:-UseSplitVerifier</argLine>
              </configuration>
            </plugin>
            <plugin>
              <groupId>org.apache.maven.plugins</groupId>
              <artifactId>maven-changes-plugin</artifactId>
              <version>2.9</version>
              <reportSets>
                <reportSet>
                  <reports>
                    <report>changes-report</report>
                  </reports>
                </reportSet>
              </reportSets>
            </plugin>
            <plugin>
              <groupId>org.apache.maven.plugins</groupId>
              <artifactId>maven-changelog-plugin</artifactId>
              <version>2.2</version>
            </plugin>
            <plugin>
              <groupId>org.apache.maven.plugins</groupId>
              <artifactId>maven-javadoc-plugin</artifactId>
              <version>2.9</version>
              <configuration>
                <sourcepath>${basedir}/src/main/java/info/freelibrary/maven</sourcepath>
                <sourceFileIncludes>
                  <include>LLP2JLPMojo.java</include>
                </sourceFileIncludes>
              </configuration>
              <reportSets>
                <reportSet>
                  <id>default</id>
                  <reports>
                    <report>javadoc</report>
                  </reports>
                </reportSet>
              </reportSets>
            </plugin>
            <plugin>
              <groupId>org.codehaus.mojo</groupId>
              <artifactId>findbugs-maven-plugin</artifactId>
              <version>2.5.2</version>
              <configuration>
                <!-- below usually would be a package, but HelpMojo causes probs -->
                <onlyAnalyze>info.freelibrary.maven.LLP2JLPMojo,org.apache.maven.artifact.factory.ArtifactFactory</onlyAnalyze>
              </configuration>
            </plugin>
            <plugin>
              <groupId>org.apache.maven.plugins</groupId>
              <artifactId>maven-checkstyle-plugin</artifactId>
              <version>2.10</version>
              <configuration>
                <consoleOutput>true</consoleOutput>
                <configLocation>src/site/resources/checkstyle/checkstyle.xml</configLocation>
                <suppressionsLocation>src/site/resources/checkstyle/checkstyle-suppressions.xml</suppressionsLocation>
              </configuration>
            </plugin>
            <plugin>
              <groupId>org.apache.maven.plugins</groupId>
              <artifactId>maven-pmd-plugin</artifactId>
              <version>3.0.1</version>
              <configuration>
                <aggregate>true</aggregate>
                <sourceEncoding>${project.build.sourceEncoding}</sourceEncoding>
                <minimumTokens>100</minimumTokens>
                <linkXRef>true</linkXRef>
                <verbose>true</verbose>
                <targetJdk>1.7</targetJdk>
                <excludes>
                  <exclude>info.freelibrary.maven.HelpMojo.java</exclude>
                </excludes>
              </configuration>
            </plugin>
            <plugin>
              <groupId>org.codehaus.mojo</groupId>
              <artifactId>taglist-maven-plugin</artifactId>
              <version>2.4</version>
              <configuration>
                <tagListOptions>
                  <tagClasses>
                    <tagClass>
                      <displayName>TODOs</displayName>
                      <tags>
                        <tag>
                          <matchString>TODO</matchString>
                          <matchType>exact</matchType>
                        </tag>
                      </tags>
                    </tagClass>
                    <tagClass>
                      <displayName>FIXMEs</displayName>
                      <tags>
                        <tag>
                          <matchString>FIXME</matchString>
                          <matchType>exact</matchType>
                        </tag>
                      </tags>
                    </tagClass>
                  </tagClasses>
                </tagListOptions>
              </configuration>
            </plugin>
            <plugin>
              <groupId>org.codehaus.mojo</groupId>
              <artifactId>cobertura-maven-plugin</artifactId>
              <version>2.5.2</version>
              <configuration>
                <aggregate>true</aggregate>
                <outputDirectory>${project.reporting.outputDirectory}/cobertura</outputDirectory>
              </configuration>
            </plugin>
          </reportPlugins>
        </configuration>
        <dependencies>
          <dependency>
            <groupId>org.apache.maven.doxia</groupId>
            <artifactId>doxia-module-markdown</artifactId>
            <version>1.3</version>
          </dependency>
          <dependency>
            <groupId>lt.velykis.maven.skins</groupId>
            <artifactId>reflow-velocity-tools</artifactId>
            <version>1.0.0</version>
          </dependency>
          <dependency>
            <groupId>org.apache.velocity</groupId>
            <artifactId>velocity</artifactId>
            <version>1.7</version>
          </dependency>
        </dependencies>
      </plugin>
      <plugin>
        <groupId>org.apache.maven.plugins</groupId>
        <artifactId>maven-surefire-plugin</artifactId>
        <version>2.16</version>
        <configuration>
          <!-- Our integration tests shouldn't be run as unit tests -->
          <excludes>
            <exclude>**/*IntegrationTest.java</exclude>
          </excludes>
        </configuration>
      </plugin>
    </plugins>

    <!-- allows publishing of generated documentation to a public s3 site -->
    <extensions>
      <extension>
        <groupId>org.kuali.maven.wagons</groupId>
        <artifactId>maven-s3-wagon</artifactId>
        <version>1.1.20</version>
      </extension>
    </extensions>
  </build>

  <profiles>
    <!-- build profile only used when publishing versions of this project -->
    <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>
            <executions>
              <execution>
                <id>sign-artifacts</id>
                <phase>verify</phase>
                <goals>
                  <goal>sign</goal>
                </goals>
              </execution>
            </executions>
          </plugin>
        </plugins>
      </build>
    </profile>
  </profiles>

  <!-- site to upload generated documentation to on formal releases -->
  <distributionManagement>
    <site>
      <id>s3.site</id>
      <url>s3://projects.freelibrary.info/llp2jlp-maven-plugin</url>
    </site>
  </distributionManagement>

  <!-- configuration used for publishing to the maven centralized repo -->
  <parent>
    <groupId>org.sonatype.oss</groupId>
    <artifactId>oss-parent</artifactId>
    <version>7</version>
  </parent>

</project>
