<?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>
  <parent>
    <groupId>ai.timefold.solver</groupId>
    <artifactId>timefold-solver-build-parent</artifactId>
    <version>0.8.39</version>
    <relativePath>../build/build-parent/pom.xml</relativePath>
  </parent>

  <artifactId>timefold-solver-migration</artifactId>

  <name>Timefold Solver Migration</name>
  <description>
    Upgrade your code with a single command.
    This migration replace all your calls to deleted/deprecated methods of Timefold with their proper alternatives.
  </description>
  <url>https://timefold.ai</url>

  <properties>
    <java.module.name>ai.timefold.solver.migration</java.module.name>
    <version.org.antlr>4.11.1</version.org.antlr>
    <version.jakarta.xml.bind.override>2.3.3</version.jakarta.xml.bind.override>
  </properties>

  <dependencyManagement>
    <dependencies>
      <!--
        Only remove the override once certain that the version is compatible with both Quarkus and Quarkus LTS.
        Keep the override up to date with OpenRewrite.
      -->
      <dependency>
        <groupId>org.antlr</groupId>
        <artifactId>antlr4</artifactId>
        <version>${version.org.antlr}</version>
      </dependency>
      <dependency>
        <groupId>org.antlr</groupId>
        <artifactId>antlr4-runtime</artifactId>
        <version>${version.org.antlr}</version>
      </dependency>
      <!-- openrewrite-maven transitively depends on jakarta.xml.bind-api with the javax package. -->
      <dependency>
        <groupId>jakarta.xml.bind</groupId>
        <artifactId>jakarta.xml.bind-api</artifactId>
        <version>${version.jakarta.xml.bind.override}</version>
      </dependency>
    </dependencies>
  </dependencyManagement>

  <dependencies>
    <dependency>
      <groupId>org.openrewrite</groupId>
      <artifactId>rewrite-core</artifactId>
    </dependency>
    <dependency>
      <groupId>org.openrewrite</groupId>
      <artifactId>rewrite-java</artifactId>
    </dependency>
    <dependency>
      <groupId>org.openrewrite</groupId>
      <artifactId>rewrite-maven</artifactId>
    </dependency>
    <dependency>
      <groupId>org.openrewrite</groupId>
      <artifactId>rewrite-gradle</artifactId>
    </dependency>
    <dependency>
      <groupId>org.openrewrite</groupId>
      <artifactId>rewrite-xml</artifactId>
    </dependency>
    <dependency>
      <groupId>org.openrewrite</groupId>
      <artifactId>rewrite-java-11</artifactId>
      <scope>runtime</scope>
    </dependency>
    <dependency>
      <groupId>org.openrewrite</groupId>
      <artifactId>rewrite-properties</artifactId>
      <scope>runtime</scope>
    </dependency>

    <!-- Testing -->
    <dependency>
      <groupId>org.junit.jupiter</groupId>
      <artifactId>junit-jupiter-api</artifactId>
      <scope>test</scope>
    </dependency>
    <dependency>
      <groupId>org.openrewrite</groupId>
      <artifactId>rewrite-test</artifactId>
      <scope>test</scope>
      <exclusions>
        <exclusion>
          <groupId>commons-logging</groupId>
          <artifactId>commons-logging</artifactId>
        </exclusion>
      </exclusions>
    </dependency>
    <dependency>
      <groupId>org.slf4j</groupId>
      <artifactId>slf4j-api</artifactId>
    </dependency>
    <dependency>
      <groupId>org.slf4j</groupId>
      <artifactId>jcl-over-slf4j</artifactId>
      <scope>runtime</scope>
    </dependency>

    <dependency>
      <groupId>ai.timefold.solver</groupId>
      <artifactId>timefold-solver-core-impl</artifactId>
      <scope>runtime</scope>
    </dependency>
  </dependencies>

  <build>
    <resources>
      <resource>
        <directory>src/main/resources</directory>
      </resource>
      <resource>
        <directory>src/main/filtered-resources</directory>
        <filtering>true</filtering>
      </resource>
    </resources>
  </build>

</project>
