<?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/xsd/maven-4.0.0.xsd">
	<modelVersion>4.0.0</modelVersion>

	<groupId>am.ik.maven</groupId>
	<artifactId>nullability-maven-plugin</artifactId>
	<version>0.3.0</version>
	<packaging>maven-plugin</packaging>
	<name>nullability-maven-plugin</name>
	<description>A Maven plugin that configures ErrorProne and NullAway for nullability checking</description>

	<properties>
		<java.version>17</java.version>
		<maven.compiler.release>${java.version}</maven.compiler.release>
		<maven.compiler.source>${java.version}</maven.compiler.source>
		<maven.compiler.target>${java.version}</maven.compiler.target>
		<project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
		<maven.version>3.9.12</maven.version>
		<spring-boot.version>4.0.2</spring-boot.version>
		<errorprone.version>2.47.0</errorprone.version>
		<nullaway.version>0.13.1</nullaway.version>
	</properties>
	<licenses>
		<license>
			<name>Apache License, Version 2.0</name>
			<url>http://www.apache.org/licenses/LICENSE-2.0.txt</url>
			<distribution>repo</distribution>
		</license>
	</licenses>
	<scm>
		<url>https://github.com/making/nullability-maven-plugin</url>
		<connection>scm:git:git@github.com:making/nullability-maven-plugin.git</connection>
		<developerConnection>scm:git:git@github.com:making/nullability-maven-plugin.git
		</developerConnection>
	</scm>
	<url>https://github.com/making/nullability-maven-plugin</url>

	<developers>
		<developer>
			<id>making</id>
			<name>Toshiaki Maki</name>
			<email>makingx@gmail.com</email>
			<url>https://twitter.com/making</url>
		</developer>
	</developers>
	<dependencies>
		<dependency>
			<groupId>org.apache.maven</groupId>
			<artifactId>maven-plugin-api</artifactId>
			<version>${maven.version}</version>
			<scope>provided</scope>
		</dependency>
		<dependency>
			<groupId>org.apache.maven</groupId>
			<artifactId>maven-core</artifactId>
			<version>${maven.version}</version>
			<scope>provided</scope>
		</dependency>
		<dependency>
			<groupId>org.apache.maven.plugin-tools</groupId>
			<artifactId>maven-plugin-annotations</artifactId>
			<version>3.15.2</version>
			<scope>provided</scope>
		</dependency>
		<dependency>
			<groupId>javax.inject</groupId>
			<artifactId>javax.inject</artifactId>
			<version>1</version>
			<scope>provided</scope>
		</dependency>
		<dependency>
			<groupId>com.google.errorprone</groupId>
			<artifactId>error_prone_core</artifactId>
			<version>${errorprone.version}</version>
			<scope>provided</scope>
		</dependency>
		<dependency>
			<groupId>com.uber.nullaway</groupId>
			<artifactId>nullaway</artifactId>
			<version>${nullaway.version}</version>
			<scope>provided</scope>
		</dependency>
		<dependency>
			<groupId>org.junit.jupiter</groupId>
			<artifactId>junit-jupiter-api</artifactId>
			<scope>test</scope>
		</dependency>
		<dependency>
			<groupId>org.junit.jupiter</groupId>
			<artifactId>junit-jupiter-engine</artifactId>
			<scope>test</scope>
		</dependency>
		<dependency>
			<groupId>org.assertj</groupId>
			<artifactId>assertj-core</artifactId>
			<scope>test</scope>
		</dependency>
		<dependency>
			<groupId>com.google.jimfs</groupId>
			<artifactId>jimfs</artifactId>
			<version>1.3.0</version>
			<scope>test</scope>
		</dependency>
	</dependencies>

	<build>
		<resources>
			<resource>
				<directory>src/main/resources</directory>
				<filtering>true</filtering>
				<includes>
					<include>am/ik/maven/nullability/defaults.properties</include>
				</includes>
			</resource>
			<resource>
				<directory>src/main/resources</directory>
				<filtering>false</filtering>
				<excludes>
					<exclude>am/ik/maven/nullability/defaults.properties</exclude>
				</excludes>
			</resource>
		</resources>
		<plugins>
			<plugin>
				<groupId>org.apache.maven.plugins</groupId>
				<artifactId>maven-plugin-plugin</artifactId>
				<version>3.15.2</version>
			</plugin>
			<plugin>
				<groupId>org.apache.maven.plugins</groupId>
				<artifactId>maven-surefire-plugin</artifactId>
				<version>3.5.4</version>
			</plugin>
			<plugin>
				<groupId>io.spring.javaformat</groupId>
				<artifactId>spring-javaformat-maven-plugin</artifactId>
				<version>0.0.47</version>
				<executions>
					<execution>
						<phase>validate</phase>
						<inherited>true</inherited>
						<goals>
							<goal>validate</goal>
						</goals>
					</execution>
				</executions>
			</plugin>
			<plugin>
				<groupId>org.apache.maven.plugins</groupId>
				<artifactId>maven-invoker-plugin</artifactId>
				<version>3.9.1</version>
				<configuration>
					<cloneProjectsTo>${project.build.directory}/it</cloneProjectsTo>
					<settingsFile>src/it/settings.xml</settingsFile>
					<localRepositoryPath>${project.build.directory}/local-repo</localRepositoryPath>
					<streamLogsOnFailures>true</streamLogsOnFailures>
					<goals>
						<goal>clean</goal>
						<goal>compile</goal>
					</goals>
				</configuration>
				<executions>
					<execution>
						<id>integration-test</id>
						<goals>
							<goal>install</goal>
							<goal>run</goal>
						</goals>
					</execution>
				</executions>
			</plugin>
			<plugin>
				<groupId>org.eclipse.sisu</groupId>
				<artifactId>sisu-maven-plugin</artifactId>
				<version>1.0.0</version>
				<executions>
					<execution>
						<id>index-project</id>
						<goals>
							<goal>main-index</goal>
						</goals>
					</execution>
				</executions>
			</plugin>
			<plugin>
				<groupId>org.sonatype.central</groupId>
				<artifactId>central-publishing-maven-plugin</artifactId>
				<version>0.10.0</version>
				<extensions>true</extensions>
				<configuration>
					<publishingServerId>central</publishingServerId>
					<autoPublish>true</autoPublish>
					<waitUntil>published</waitUntil>
				</configuration>
			</plugin>
		</plugins>
	</build>

	<profiles>
		<profile>
			<id>maven4-it</id>
			<activation>
				<property>
					<name>maven4.home</name>
				</property>
			</activation>
			<build>
				<plugins>
					<plugin>
						<groupId>org.apache.maven.plugins</groupId>
						<artifactId>maven-invoker-plugin</artifactId>
						<executions>
							<execution>
								<id>maven4-integration-test</id>
								<goals>
									<goal>run</goal>
								</goals>
								<configuration>
									<mavenHome>${maven4.home}</mavenHome>
									<cloneProjectsTo>${project.build.directory}/it-maven4</cloneProjectsTo>
								</configuration>
							</execution>
						</executions>
					</plugin>
				</plugins>
			</build>
		</profile>
	</profiles>

	<dependencyManagement>
		<dependencies>
			<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>
</project>
