<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>

  <!-- The Basics -->
  <groupId>io.sitoolkit.cv</groupId>
  <artifactId>sit-cv</artifactId>
  <version>1.1.1</version>
  <packaging>pom</packaging>

  <dependencies>
    <dependency>
      <groupId>junit</groupId>
      <artifactId>junit</artifactId>
      <scope>test</scope>
    </dependency>
    <dependency>
      <groupId>org.hamcrest</groupId>
      <artifactId>hamcrest-all</artifactId>
      <version>1.3</version>
      <scope>test</scope>
    </dependency>
  </dependencies>

  <parent>
    <groupId>org.sonatype.oss</groupId>
    <artifactId>oss-parent</artifactId>
    <version>7</version>
  </parent>

  <dependencyManagement>
    <dependencies>
      <dependency>
        <groupId>commons-io</groupId>
        <artifactId>commons-io</artifactId>
        <version>2.11.0</version>
      </dependency>
      <dependency>
        <groupId>org.springframework.boot</groupId>
        <artifactId>spring-boot-dependencies</artifactId>
        <version>${spring.boot.version}</version>
        <type>pom</type>
        <scope>import</scope>
      </dependency>
    </dependencies>
  </dependencyManagement>

  <properties>
    <project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
    <maven.compiler.source>11</maven.compiler.source>
    <maven.compiler.target>11</maven.compiler.target>
    <spring.boot.version>2.1.7.RELEASE</spring.boot.version>
    <ant.target>deploy</ant.target>
  </properties>


  <modules>
    <module>sit-cv-tools</module>
    <module>sit-cv-app</module>
    <module>sit-cv-core</module>
    <module>sit-cv-maven-plugin</module>
  </modules>

  <!-- Build Settings -->
  <build>

    <defaultGoal>antrun:run</defaultGoal>

    <plugins>

      <plugin>
        <artifactId>maven-antrun-plugin</artifactId>
        <version>1.8</version>
        <inherited>false</inherited>
        <dependencies>
          <dependency>
            <groupId>org.apache.ant</groupId>
            <artifactId>ant</artifactId>
            <version>1.10.12</version>
          </dependency>
        </dependencies>
        <configuration>
          <target>
            <ant antfile="build.xml" target="${ant.target}" />
          </target>
        </configuration>
      </plugin>

    </plugins>

  </build>

  <!-- More Project Information -->
  <name>sit-cv</name>
  <description>SI-Toolkit Code Visializer</description>
  <url>https://sitoolkit.org/</url>
  <licenses>
    <license>
      <name>The Apache Software License, Version 2.0</name>
      <url>http://www.apache.org/licenses/LICENSE-2.0.txt</url>
      <distribution>repo</distribution>
      <comments>A business-friendly OSS license</comments>
    </license>
  </licenses>
  <developers>
    <developer>
      <id>yuichi.kuwahara</id>
      <name>Yuichi Kuwahara</name>
      <email>yuichi.kuwahara.0@gmail.com</email>
    </developer>
  </developers>


  <!-- Environment Settings -->
  <scm>
    <connection>scm:git:git//github.com/sitoolkit/sit-cv.git</connection>
    <developerConnection>scm:git:git//github.com/sitoolkit/sit-cv.git</developerConnection>
    <url>https://github.com/sitoolkit/sit-wt-cv.git</url>
  </scm>
  <prerequisites>
    <maven>3.0</maven>
  </prerequisites>
  <distributionManagement>
    <snapshotRepository>
      <id>sonatype-nexus-snapshots</id>
      <name>Snapshot Repository</name>
      <url>https://oss.sonatype.org/content/repositories/snapshots</url>
    </snapshotRepository>
    <repository>
      <id>sonatype-nexus-staging</id>
      <name>Maven Central Repository</name>
      <url>https://oss.sonatype.org/service/local/staging/deploy/maven2/</url>
    </repository>
  </distributionManagement>

  <profiles>

    <profile>
      <id>release</id>

      <properties>
        <maven.test.skip>true</maven.test.skip>
      </properties>

      <build>
        <plugins>

          <plugin>
            <groupId>org.apache.maven.plugins</groupId>
            <artifactId>maven-source-plugin</artifactId>
            <executions>
              <execution>
                <id>attach-sources</id>
                <phase>verify</phase>
                <goals>
                  <goal>jar-no-fork</goal>
                </goals>
              </execution>
            </executions>
          </plugin>

          <plugin>
            <groupId>org.apache.maven.plugins</groupId>
            <artifactId>maven-javadoc-plugin</artifactId>
            <executions>
              <execution>
                <id>attach-javadocs</id>
                <phase>verify</phase>
                <goals>
                  <goal>jar</goal>
                </goals>
              </execution>
            </executions>
          </plugin>

          <plugin>
            <groupId>org.apache.maven.plugins</groupId>
            <artifactId>maven-gpg-plugin</artifactId>
            <version>1.6</version>
            <executions>
              <execution>
                <id>sign-artifacts</id>
                <phase>verify</phase>
                <goals>
                  <goal>sign</goal>
                </goals>
              </execution>
            </executions>
            <configuration>
              <gpgArguments>
                <arg>--pinentry-mode</arg>
                <arg>loopback</arg>
              </gpgArguments>
            </configuration>
          </plugin>

        </plugins>
      </build>
    </profile>

    <profile>
      <id>analyze</id>

      <build>
        <plugins>

          <plugin>
            <groupId>org.jacoco</groupId>
            <artifactId>jacoco-maven-plugin</artifactId>
            <version>0.8.3</version>
            <executions>
              <execution>
                <goals>
                  <goal>prepare-agent</goal>
                </goals>
              </execution>
            </executions>
          </plugin>

        </plugins>
      </build>
    </profile>

  </profiles>

</project>