<?xml version="1.0" encoding="UTF-8"?>
<!--
  Copyright 2017 Rob Spoor

  Licensed under the Apache License, Version 2.0 (the "License");
  you may not use this file except in compliance with the License.
  You may obtain a copy of the License at

      http://www.apache.org/licenses/LICENSE-2.0

  Unless required by applicable law or agreed to in writing, software
  distributed under the License is distributed on an "AS IS" BASIS,
  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
  See the License for the specific language governing permissions and
  limitations under the License.
-->

<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>

  <parent>
    <groupId>com.github.robtimus</groupId>
    <artifactId>robtimus-parent</artifactId>
    <version>1.12</version>
    <relativePath />
  </parent>

  <artifactId>i18n-maven-plugin</artifactId>
  <version>3.1</version>
  <packaging>maven-plugin</packaging>

  <name>I18N Maven Plugin</name>
  <description>A Maven plugin for generating accessor classes for I18N resources</description>
  <url>https://robtimus.github.io/i18n-maven-plugin/</url>
  <inceptionYear>2017</inceptionYear>

  <licenses>
    <license>
      <name>The Apache Software License, Version 2.0</name>
      <url>https://www.apache.org/licenses/LICENSE-2.0.txt</url>
    </license>
  </licenses>

  <developers>
    <developer>
      <name>Rob Spoor</name>
      <email>robtimus@users.noreply.github.com</email>
    </developer>
  </developers>

  <scm>
    <connection>scm:git:git@github.com:robtimus/i18n-maven-plugin.git</connection>
    <developerConnection>scm:git:git@github.com:robtimus/i18n-maven-plugin.git</developerConnection>
    <tag>3.1</tag>
    <url>https://github.com/robtimus/i18n-maven-plugin</url>
  </scm>

  <issueManagement>
    <system>GitHub</system>
    <url>https://github.com/robtimus/i18n-maven-plugin/issues</url>
  </issueManagement>

  <properties>
    <version.commons-io>2.17.0</version.commons-io>
    <version.freemarker>2.3.33</version.freemarker>
    <version.maven>3.8.2</version.maven>
    <version.maven-annotations>3.8.1</version.maven-annotations>

    <version.plugin.maven>3.8.1</version.plugin.maven>
  </properties>

  <dependencies>
    <dependency>
      <groupId>org.apache.maven</groupId>
      <artifactId>maven-core</artifactId>
      <version>${version.maven}</version>
      <scope>provided</scope>
    </dependency>

    <dependency>
      <groupId>org.apache.maven</groupId>
      <artifactId>maven-plugin-api</artifactId>
      <version>${version.maven}</version>
      <scope>provided</scope>
    </dependency>

    <dependency>
      <groupId>org.apache.maven.plugin-tools</groupId>
      <artifactId>maven-plugin-annotations</artifactId>
      <version>${version.maven-annotations}</version>
      <scope>provided</scope>
    </dependency>

    <dependency>
      <groupId>commons-io</groupId>
      <artifactId>commons-io</artifactId>
      <version>${version.commons-io}</version>
    </dependency>

    <dependency>
      <groupId>org.freemarker</groupId>
      <artifactId>freemarker</artifactId>
      <version>${version.freemarker}</version>
    </dependency>

    <dependency>
      <groupId>org.junit.jupiter</groupId>
      <artifactId>junit-jupiter</artifactId>
      <scope>test</scope>
    </dependency>

    <dependency>
      <groupId>org.hamcrest</groupId>
      <artifactId>hamcrest</artifactId>
      <scope>test</scope>
    </dependency>

    <dependency>
      <groupId>org.mockito</groupId>
      <artifactId>mockito-core</artifactId>
      <scope>test</scope>
    </dependency>
  </dependencies>

  <build>
    <pluginManagement>
      <plugins>
        <plugin>
          <groupId>org.apache.maven.plugins</groupId>
          <artifactId>maven-javadoc-plugin</artifactId>
          <configuration>
            <sourcepath>${project.basedir}/src/main/java</sourcepath>
          </configuration>
        </plugin>
      </plugins>
    </pluginManagement>

    <plugins>
      <plugin>
        <groupId>org.apache.maven.plugins</groupId>
        <artifactId>maven-compiler-plugin</artifactId>
      </plugin>

      <plugin>
        <groupId>org.apache.maven.plugins</groupId>
        <artifactId>maven-dependency-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-source-plugin</artifactId>
      </plugin>

      <plugin>
        <groupId>org.apache.maven.plugins</groupId>
        <artifactId>maven-resources-plugin</artifactId>
      </plugin>

      <plugin>
        <groupId>org.apache.maven.plugins</groupId>
        <artifactId>maven-checkstyle-plugin</artifactId>
      </plugin>

      <plugin>
        <groupId>org.apache.maven.plugins</groupId>
        <artifactId>maven-javadoc-plugin</artifactId>
      </plugin>

      <plugin>
        <groupId>org.apache.maven.plugins</groupId>
        <artifactId>maven-plugin-plugin</artifactId>
        <version>${version.plugin.maven}</version>
        <executions>
          <execution>
            <phase>generate-sources</phase>
            <goals>
              <goal>helpmojo</goal>
            </goals>
            <configuration>
              <helpPackageName>com.github.robtimus.maven.plugins.i18n</helpPackageName>
            </configuration>
          </execution>
        </executions>
      </plugin>

      <plugin>
        <groupId>com.github.robtimus</groupId>
        <artifactId>build-helper-maven-plugin</artifactId>
        <configuration>
          <siteIndexTitle>Introduction</siteIndexTitle>
        </configuration>
      </plugin>

      <plugin>
        <groupId>org.apache.maven.plugins</groupId>
        <artifactId>maven-clean-plugin</artifactId>
      </plugin>

      <plugin>
        <groupId>org.apache.maven.plugins</groupId>
        <artifactId>maven-surefire-plugin</artifactId>
      </plugin>

      <plugin>
        <groupId>org.apache.maven.plugins</groupId>
        <artifactId>maven-install-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-gpg-plugin</artifactId>
      </plugin>

      <plugin>
        <groupId>org.sonatype.plugins</groupId>
        <artifactId>nexus-staging-maven-plugin</artifactId>
      </plugin>

      <plugin>
        <groupId>org.apache.maven.plugins</groupId>
        <artifactId>maven-deploy-plugin</artifactId>
      </plugin>

      <plugin>
        <groupId>org.apache.maven.plugins</groupId>
        <artifactId>maven-site-plugin</artifactId>
      </plugin>

      <plugin>
        <groupId>org.apache.maven.plugins</groupId>
        <artifactId>maven-project-info-reports-plugin</artifactId>
      </plugin>
    </plugins>
  </build>

  <reporting>
    <plugins>
      <plugin>
        <groupId>org.apache.maven.plugins</groupId>
        <artifactId>maven-plugin-report-plugin</artifactId>
        <version>${version.plugin.maven}</version>
      </plugin>
    </plugins>
  </reporting>

  <profiles>
    <profile>
      <id>generate-messages</id>

      <build>
        <plugins>
          <plugin>
            <groupId>com.github.robtimus</groupId>
            <artifactId>i18n-maven-plugin</artifactId>
            <version>${project.version}</version>
            <executions>
              <execution>
                <goals>
                  <goal>generate</goal>
                </goals>
                <configuration>
                  <bundleName>com.github.robtimus.maven.plugins.i18n.i18n</bundleName>
                  <className>com.github.robtimus.maven.plugins.i18n.Messages</className>
                  <outputDirectory>${project.basedir}/src/main/java</outputDirectory>
                  <licenseText>Apache-2.0</licenseText>
                  <licenseCopyrightYear>2017</licenseCopyrightYear>
                  <licenseCopyrightHolder>Rob Spoor</licenseCopyrightHolder>
                  <publicVisibility>false</publicVisibility>
                  <suppressWarnings>nls</suppressWarnings>
                </configuration>
              </execution>
            </executions>
          </plugin>
        </plugins>
      </build>
    </profile>

    <profile>
      <id>maven-3.9</id>

      <properties>
        <version.maven>3.9.0</version.maven>
      </properties>
    </profile>

    <profile>
      <id>maven-4</id>

      <properties>
        <version.maven>4.0.0-alpha-4</version.maven>
      </properties>
    </profile>
  </profiles>
</project>
