<?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">
  <parent>
    <artifactId>schema2proto-parent</artifactId>
    <groupId>no.entur</groupId>
    <version>1.121.0</version>
  </parent>
  <modelVersion>4.0.0</modelVersion>
  <artifactId>schema2proto-lib</artifactId>
  <name>schema2proto Maven Plugin</name>
  <version>1.121.0</version>
  <description>schema2proto Maven Plugin</description>
  <url>https://github.com/entur/schema2proto</url>
  <build>
    <plugins>
      <plugin>
        <groupId>com.diffplug.spotless</groupId>
        <artifactId>spotless-maven-plugin</artifactId>
        <configuration>
          <java>
            <eclipse>
              <file>../codestyle/jdt_codestyle.xml</file>
              <version>4.9.0</version>
            </eclipse>
            <removeUnusedImports />
            <importOrder>
              <file>../codestyle/jdt.importorder</file>
            </importOrder>
          </java>
        </configuration>
      </plugin>
      <plugin>
        <artifactId>maven-shade-plugin</artifactId>
        <version>3.6.2</version>
        <executions>
          <execution>
            <phase>package</phase>
            <goals>
              <goal>shade</goal>
            </goals>
            <configuration>
              <transformers>
                <transformer>
                  <manifestEntries>
                    <Main-Class>no.entur.schema2proto.generateproto.Schema2Proto</Main-Class>
                  </manifestEntries>
                </transformer>
              </transformers>
            </configuration>
          </execution>
        </executions>
      </plugin>
      <plugin>
        <artifactId>maven-dependency-plugin</artifactId>
        <executions>
          <execution>
            <id>unpack</id>
            <phase>generate-test-resources</phase>
            <goals>
              <goal>unpack</goal>
            </goals>
            <configuration>
              <artifactItems>
                <artifactItem>
                  <groupId>com.google.protobuf</groupId>
                  <artifactId>protobuf-java</artifactId>
                  <type>jar</type>
                  <overWrite>true</overWrite>
                  <includes>**/*.proto</includes>
                  <outputDirectory>${project.build.directory}/proto_deps</outputDirectory>
                </artifactItem>
                <artifactItem>
                  <groupId>build.buf</groupId>
                  <artifactId>protovalidate</artifactId>
                  <type>jar</type>
                  <overWrite>true</overWrite>
                  <includes>**/*.proto</includes>
                  <outputDirectory>${project.build.directory}/proto_deps</outputDirectory>
                </artifactItem>
              </artifactItems>
            </configuration>
          </execution>
        </executions>
      </plugin>
    </plugins>
  </build>
  <dependencies>
    <dependency>
      <groupId>io.github.java-diff-utils</groupId>
      <artifactId>java-diff-utils</artifactId>
      <version>4.17</version>
      <scope>test</scope>
    </dependency>
    <dependency>
      <groupId>org.junit.jupiter</groupId>
      <artifactId>junit-jupiter</artifactId>
      <version>6.1.0</version>
      <scope>test</scope>
      <exclusions>
        <exclusion>
          <artifactId>junit-jupiter-api</artifactId>
          <groupId>org.junit.jupiter</groupId>
        </exclusion>
        <exclusion>
          <artifactId>junit-jupiter-params</artifactId>
          <groupId>org.junit.jupiter</groupId>
        </exclusion>
        <exclusion>
          <artifactId>junit-jupiter-engine</artifactId>
          <groupId>org.junit.jupiter</groupId>
        </exclusion>
      </exclusions>
    </dependency>
  </dependencies>
</project>
