<?xml version="1.0" encoding="UTF-8"?>
<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/maven-v4_0_0.xsd">
    <modelVersion>4.0.0</modelVersion>

    <groupId>com.github.oscana</groupId>
    <artifactId>oscana-s2n-runtime-sastruts</artifactId>
    <version>1.0.0</version>
    <name>${project.artifactId}</name>
    <description>Oscana</description>
    <url>https://github.com/oscana</url>

    <licenses>
      <license>
        <name>The Apache License, Version 2.0</name>
        <url>http://www.apache.org/licenses/LICENSE-2.0.txt</url>
      </license>
    </licenses>

  <distributionManagement>
    <snapshotRepository>
      <id>ossrh</id>
      <url>https://s01.oss.sonatype.org/content/repositories/snapshots</url>
    </snapshotRepository>
    <repository>
      <id>ossrh</id>
      <name>Nexus Release Repository</name>
      <url>https://s01.oss.sonatype.org/service/local/staging/deploy/maven2/</url>
    </repository>
  </distributionManagement>

    <developers>
      <developer>
        <id>oscana</id>
        <name>Oscana</name>
        <email>s2n@tis.co.jp</email>
        <organization>oscana</organization>
        <organizationUrl>https://github.com/oscana</organizationUrl>
      </developer>
    </developers>

    <scm>
      <connection>scm:git:git://github.com/oscana/${project.artifactId}.git</connection>
      <developerConnection>scm:git:git://github.com/oscana/${project.artifactId}.git</developerConnection>
      <url>https://github.com/oscana/${project.artifactId}/tree/master</url>
    </scm>


    <properties>
        <maven.compiler.source>1.8</maven.compiler.source>
        <maven.compiler.target>1.8</maven.compiler.target>
        <project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
        <!-- ソース及びclassファイルが準拠するJavaのバージョン -->
        <java.version>1.8</java.version>

    </properties>

    <dependencyManagement>
        <dependencies>
            <dependency>
                <groupId>com.nablarch.profile</groupId>
                <artifactId>nablarch-bom</artifactId>
                <version>5u18</version>
                <type>pom</type>
                <scope>import</scope>
            </dependency>
        </dependencies>
    </dependencyManagement>


        <dependencies>
        <dependency>
            <groupId>com.github.oscana</groupId>
            <artifactId>oscana-s2n-runtime-struts</artifactId>
            <version>1.0.0</version>
        </dependency>

        <dependency>
            <groupId>org.jmockit</groupId>
            <artifactId>jmockit</artifactId>
            <version>1.48</version>
            <scope>test</scope>
        </dependency>

        <dependency>
            <groupId>com.nablarch.framework</groupId>
            <artifactId>nablarch-testing</artifactId>
            <scope>test</scope>
            <!--NablarchのテスティングフレームワークがJSPのビルド時に使用するコンパイラを差し替えるために、 依存関係からデフォルトのecjを除去。 -->
            <exclusions>
                <exclusion>
                    <groupId>org.eclipse.jdt.core.compiler</groupId>
                    <artifactId>ecj</artifactId>
                </exclusion>
            </exclusions>
        </dependency>

        <dependency>
            <groupId>javax.servlet</groupId>
            <artifactId>javax.servlet-api</artifactId>
            <version>3.1.0</version>
            <scope>provided</scope>
        </dependency>

        <dependency>
            <groupId>javax.servlet.jsp</groupId>
            <artifactId>javax.servlet.jsp-api</artifactId>
            <version>2.3.1</version>
            <scope>provided</scope>
        </dependency>

        <dependency>
            <groupId>javax.servlet.jsp.jstl</groupId>
            <artifactId>javax.servlet.jsp.jstl-api</artifactId>
            <version>1.2.1</version>
        </dependency>

        <dependency>
            <groupId>org.hibernate</groupId>
            <artifactId>hibernate-validator</artifactId>
            <version>5.1.3.Final</version>
        </dependency>

        <dependency>
           <groupId>com.nablarch.dev</groupId>
           <artifactId>nablarch-test-support</artifactId>
           <version>0.2.0</version>
           <scope>test</scope>
        </dependency>

        <dependency>
            <groupId>junit</groupId>
            <artifactId>junit</artifactId>
            <version>4.12</version>
            <scope>test</scope>
        </dependency>

    </dependencies>

    <build>
        <plugins>
                  <plugin>
            <groupId>org.apache.maven.plugins</groupId>
            <artifactId>maven-gpg-plugin</artifactId>
            <version>1.5</version>
            <executions>
              <execution>
                <id>sign-artifacts</id>
                <phase>verify</phase>
                <goals>
                  <goal>sign</goal>
                </goals>
              </execution>
            </executions>
          </plugin>
            <plugin>
                <groupId>org.apache.maven.plugins</groupId>
                <artifactId>maven-surefire-plugin</artifactId>
                <version>3.0.0-M5</version>
                <configuration>
                    <!-- MANIFEST.MFでClass-Pathを指定すると、依存jar内で定義されているtaglibのuriを正しく解決してくれない。 -->
                    <useManifestOnlyJar>false</useManifestOnlyJar>
                    <testFailureIgnore>true</testFailureIgnore>
                    <argLine>${argLine} -javaagent:${settings.localRepository}/org/jmockit/jmockit/1.48/jmockit-1.48.jar</argLine>
                </configuration>
            </plugin>
            <!-- カバレッジ取得 -->
            <plugin>
               <groupId>org.jacoco</groupId>
               <artifactId>jacoco-maven-plugin</artifactId>
               <version>0.8.5</version>
               <executions>
                 <execution>
                  <goals>
                    <goal>prepare-agent</goal>
                  </goals>
                 </execution>
               <execution>
                <id>report</id>
                <phase>test</phase>
                <goals>
                    <goal>report</goal>
                </goals>
               </execution>
              </executions>
            </plugin>
             <plugin>
               <groupId>org.apache.maven.plugins</groupId>
               <artifactId>maven-source-plugin</artifactId>
               <version>3.0.1</version>
               <executions>
                 <execution>
                   <phase>package</phase>
                   <goals>
                     <goal>jar</goal>
                   </goals>
                 </execution>
               </executions>
             </plugin>
            <!-- Javadoc -->
            <plugin>
              <groupId>org.apache.maven.plugins</groupId>
              <artifactId>maven-javadoc-plugin</artifactId>
              <executions>
                <execution>
                  <phase>package</phase>
                  <goals>
                    <goal>jar</goal>
                  </goals>
                </execution>
              </executions>
              <configuration>
                <doctitle>互換ライブラリ(SAStruts)</doctitle>
                <encoding>UTF-8</encoding>
                <charset>UTF-8</charset>
                <bottom>&amp;nbsp;</bottom>
                                <failOnError>false</failOnError>
              <additionalDependencies>
                   <additionalDependency>
                      <groupId>struts</groupId>
                      <artifactId>struts</artifactId>
                      <version>1.2.9</version>
                   </additionalDependency>
                   <additionalDependency>
                     <groupId>org.seasar.sastruts</groupId>
                     <artifactId>sa-struts</artifactId>
                     <version>1.0.0</version>
                   </additionalDependency>
                </additionalDependencies>

              </configuration>
            </plugin>
        </plugins>
    </build>

    <reporting>
    <plugins>
      <plugin>
        <groupId>org.jacoco</groupId>
        <artifactId>jacoco-maven-plugin</artifactId>
        <reportSets>
          <reportSet>
            <reports>
              <report>report</report>
            </reports>
          </reportSet>
        </reportSets>
      </plugin>
    </plugins>
  </reporting>
</project>
