<?xml version="1.0" encoding="UTF-8"?>
<!--
   Licensed to the Apache Software Foundation (ASF) under one
   or more contributor license agreements.  See the NOTICE file
   distributed with this work for additional information
   regarding copyright ownership.  The ASF licenses this file
   to you 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>org.apache.uima</groupId>
    <artifactId>parent-pom</artifactId>
    <relativePath />
    <version>16</version>
  </parent>

  <artifactId>uimaj-io-json</artifactId>
  <version>0.5.0</version>
  <name>Apache UIMA: ${project.artifactId}: JSON CAS</name>
  <description>JSON support for UIMA SDK</description>

  <scm>
    <connection>scm:git:https://github.com/apache/uima-uimaj-io-jsoncas/</connection>
    <developerConnection>scm:git:https://github.com/apache/uima-uimaj-io-jsoncas/</developerConnection>
    <url>https://github.com/apache/uima-uimaj-io-jsoncas/</url>
    <tag>uimaj-io-json-0.5.0</tag>
  </scm>

  <issueManagement>
    <system>Github</system>
    <url>https://github.com/apache/uima-uimaj-io-jsoncas/issues</url>
  </issueManagement>

  <properties>
    <jiraVersion>${parsedVersion.majorVersion}.${parsedVersion.minorVersion}.${parsedVersion.incrementalVersion}jsoncas</jiraVersion>
    <uima-version>3.3.0</uima-version>
    <slf4j-version>1.7.36</slf4j-version>
    <log4j-version>2.20.0</log4j-version>
    <jackson-version>2.14.2</jackson-version>
    <jackson-databind-version>${jackson-version}</jackson-databind-version>
    <junit-version>5.9.2</junit-version>
    <jsonunit-version>2.36.1</jsonunit-version>

    <maven.compiler.target>1.8</maven.compiler.target>
    <maven.compiler.source>1.8</maven.compiler.source>
  </properties>

  <dependencies>
    <dependency>
      <groupId>org.apache.uima</groupId>
      <artifactId>uimaj-core</artifactId>
      <version>${uima-version}</version>
    </dependency>

    <dependency>
      <groupId>com.fasterxml.jackson.core</groupId>
      <artifactId>jackson-core</artifactId>
      <version>${jackson-version}</version>
    </dependency>
    <dependency>
      <groupId>com.fasterxml.jackson.core</groupId>
      <artifactId>jackson-databind</artifactId>
      <version>${jackson-databind-version}</version>
    </dependency>
    <dependency>
      <groupId>com.fasterxml.jackson.core</groupId>
      <artifactId>jackson-annotations</artifactId>
      <version>${jackson-version}</version>
    </dependency>

    <dependency>
      <groupId>org.junit.jupiter</groupId>
      <artifactId>junit-jupiter-engine</artifactId>
      <version>${junit-version}</version>
      <scope>test</scope>
    </dependency>
    <dependency>
      <groupId>org.junit.jupiter</groupId>
      <artifactId>junit-jupiter-params</artifactId>
      <version>${junit-version}</version>
      <scope>test</scope>
    </dependency>
    <dependency>
      <groupId>org.junit.jupiter</groupId>
      <artifactId>junit-jupiter-api</artifactId>
      <version>${junit-version}</version>
      <scope>test</scope>
    </dependency>
    <dependency>
      <groupId>org.junit.jupiter</groupId>
      <artifactId>junit-jupiter-migrationsupport</artifactId>
      <version>${junit-version}</version>
      <scope>test</scope>
    </dependency>

    <dependency>
      <groupId>org.apache.uima</groupId>
      <artifactId>uimaj-test-util</artifactId>
      <version>${uima-version}</version>
      <scope>test</scope>
    </dependency>
    <dependency>
      <groupId>org.apache.uima</groupId>
      <artifactId>uimaj-core</artifactId>
      <version>${uima-version}</version>
      <classifier>tests</classifier>
      <scope>test</scope>
    </dependency>
    <dependency>
      <groupId>org.slf4j</groupId>
      <artifactId>slf4j-jdk14</artifactId>
      <version>${slf4j-version}</version>
      <scope>test</scope>
    </dependency>
    <dependency>
      <groupId>org.assertj</groupId>
      <artifactId>assertj-core</artifactId>
      <version>3.22.0</version>
      <scope>test</scope>
    </dependency>
    <dependency>
      <groupId>org.skyscreamer</groupId>
      <artifactId>jsonassert</artifactId>
      <version>1.5.0</version>
      <scope>test</scope>
    </dependency>
    <dependency>
      <groupId>net.javacrumbs.json-unit</groupId>
      <artifactId>json-unit-assertj</artifactId>
      <version>${jsonunit-version}</version>
      <scope>test</scope>
    </dependency>
    <dependency>
      <groupId>net.javacrumbs.json-unit</groupId>
      <artifactId>json-unit-json-path</artifactId>
      <version>${jsonunit-version}</version>
      <scope>test</scope>
    </dependency>
    <dependency>
      <groupId>org.apache.commons</groupId>
      <artifactId>commons-lang3</artifactId>
      <version>3.12.0</version>
      <scope>test</scope>
    </dependency>
    <dependency>
      <groupId>commons-io</groupId>
      <artifactId>commons-io</artifactId>
      <version>2.11.0</version>
      <scope>test</scope>
    </dependency>
    <dependency>
      <groupId>org.apache.commons</groupId>
      <artifactId>commons-csv</artifactId>
      <version>1.9.0</version>
      <scope>test</scope>
    </dependency>
  </dependencies>

  <build>
    <plugins>
      <plugin>
        <groupId>org.apache.maven.plugins</groupId>
        <artifactId>maven-toolchains-plugin</artifactId>
        <executions>
          <execution>
            <goals>
              <goal>toolchain</goal>
            </goals>
          </execution>
        </executions>
        <configuration>
          <toolchains>
            <jdk>
              <version>${maven.compiler.target}</version>
            </jdk>
          </toolchains>
        </configuration>
      </plugin>
    </plugins>

    <pluginManagement>
      <plugins>
        <plugin>
          <groupId>org.apache.rat</groupId>
          <artifactId>apache-rat-plugin</artifactId>
          <executions>
            <execution>
              <id>default-cli</id>
              <configuration>
                <excludes combine.children="append">
                  <exclude>src/test/resources/**/data.json</exclude>
                  <exclude>src/test/resources/**/debug.xmi</exclude>
                  <exclude>src/test/resources/**/typesystem.xml</exclude>
                  <exclude>src/test/resources/**/debug-typesystem.xml</exclude>
                </excludes>
              </configuration>
            </execution>
          </executions>
        </plugin>
      </plugins>
    </pluginManagement>
  </build>

  <profiles>
    <profile>
      <id>apache-release</id>

      <build>
        <plugins>
          <plugin>
            <groupId>org.apache.maven.plugins</groupId>
            <artifactId>maven-antrun-plugin</artifactId>
            <inherited>false</inherited>
            <executions>
              <execution>
                <phase>install</phase>
                <goals>
                  <goal>run</goal>
                </goals>
                <configuration>
                  <target>
                    <mkdir dir="${staging-local-root}/${staging-folder}" />
                    <copy todir="${staging-local-root}/${staging-folder}">
                      <fileset dir="${project.build.directory}">
                        <include name="uimaj-io-json-${project.version}-*.zip" />
                        <include name="uimaj-io-json-${project.version}-*.zip.asc" />
                        <include name="uimaj-io-json-${project.version}-*.zip.sha512" />
                      </fileset>
                    </copy>
                  </target>
                </configuration>
              </execution>
            </executions>
          </plugin>
        </plugins>
      </build>
    </profile>
  </profiles>
</project>