<?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 https://maven.apache.org/xsd/maven-4.0.0.xsd">
	<modelVersion>4.0.0</modelVersion>
	<parent>
		<groupId>org.springframework.boot</groupId>
		<artifactId>spring-boot-tools</artifactId>
		<version>${revision}</version>
	</parent>
	<artifactId>spring-boot-maven-plugin</artifactId>
	<packaging>maven-plugin</packaging>
	<name>Spring Boot Maven Plugin</name>
	<description>Spring Boot Maven Plugin</description>
	<properties>
		<main.basedir>${basedir}/../../..</main.basedir>
		<maven.version>3.3.9</maven.version>
	</properties>
	<scm>
		<url>${git.url}</url>
		<connection>${git.connection}</connection>
		<developerConnection>${git.developerConnection}</developerConnection>
	</scm>
	<dependencies>
		<!-- Compile -->
		<dependency>
			<groupId>org.springframework.boot</groupId>
			<artifactId>spring-boot-loader-tools</artifactId>
		</dependency>
		<dependency>
			<groupId>org.apache.maven</groupId>
			<artifactId>maven-archiver</artifactId>
		</dependency>
		<dependency>
			<groupId>org.apache.maven</groupId>
			<artifactId>maven-artifact</artifactId>
		</dependency>
		<dependency>
			<groupId>org.apache.maven</groupId>
			<artifactId>maven-core</artifactId>
		</dependency>
		<dependency>
			<groupId>org.apache.maven</groupId>
			<artifactId>maven-model</artifactId>
		</dependency>
		<dependency>
			<groupId>org.apache.maven</groupId>
			<artifactId>maven-plugin-api</artifactId>
		</dependency>
		<dependency>
			<groupId>org.apache.maven</groupId>
			<artifactId>maven-settings</artifactId>
		</dependency>
		<dependency>
			<groupId>org.apache.maven.shared</groupId>
			<artifactId>maven-common-artifact-filters</artifactId>
		</dependency>
		<dependency>
			<groupId>org.codehaus.plexus</groupId>
			<artifactId>plexus-archiver</artifactId>
			<exclusions>
				<exclusion>
					<groupId>org.codehaus.plexus</groupId>
					<artifactId>plexus-container-default</artifactId>
				</exclusion>
				<exclusion>
					<groupId>org.codehaus.plexus</groupId>
					<artifactId>plexus-component-api</artifactId>
				</exclusion>
			</exclusions>
		</dependency>
		<dependency>
			<groupId>org.codehaus.plexus</groupId>
			<artifactId>plexus-utils</artifactId>
		</dependency>
		<dependency>
			<groupId>org.sonatype.plexus</groupId>
			<artifactId>plexus-build-api</artifactId>
		</dependency>
		<!-- Optional -->
		<dependency>
			<groupId>org.apache.maven.plugins</groupId>
			<artifactId>maven-shade-plugin</artifactId>
			<optional>true</optional>
		</dependency>
		<!-- Provided -->
		<dependency>
			<groupId>org.apache.maven.plugin-tools</groupId>
			<artifactId>maven-plugin-annotations</artifactId>
			<scope>provided</scope>
		</dependency>
	</dependencies>
	<build>
		<plugins>
			<plugin>
				<groupId>org.apache.maven.plugins</groupId>
				<artifactId>maven-jar-plugin</artifactId>
			</plugin>
			<plugin>
				<groupId>org.apache.maven.plugins</groupId>
				<artifactId>maven-plugin-plugin</artifactId>
				<configuration>
					<goalPrefix>spring-boot</goalPrefix>
					<skipErrorNoDescriptorsFound>true</skipErrorNoDescriptorsFound>
				</configuration>
				<executions>
					<execution>
						<id>generate-descriptor</id>
						<goals>
							<goal>descriptor</goal>
						</goals>
					</execution>
					<execution>
						<id>generated-helpmojo</id>
						<goals>
							<goal>helpmojo</goal>
						</goals>
					</execution>
				</executions>
			</plugin>
		</plugins>
	</build>
	<profiles>
		<profile>
			<id>integration</id>
			<activation>
				<activeByDefault>true</activeByDefault>
			</activation>
			<build>
				<plugins>
					<plugin>
						<groupId>org.apache.maven.plugins</groupId>
						<artifactId>maven-invoker-plugin</artifactId>
						<configuration>
							<localRepositoryPath>${project.build.directory}/local-repo</localRepositoryPath>
						</configuration>
						<executions>
							<execution>
								<id>prepare-integration-test</id>
								<phase>pre-integration-test</phase>
								<goals>
									<goal>install</goal>
								</goals>
							</execution>
							<execution>
								<id>integration-test</id>
								<goals>
									<goal>run</goal>
								</goals>
								<configuration>
									<cloneProjectsTo>${project.build.directory}/it</cloneProjectsTo>
									<settingsFile>src/it/settings.xml</settingsFile>
									<postBuildHookScript>verify</postBuildHookScript>
									<addTestClassPath>true</addTestClassPath>
									<skipInvocation>${skipTests}</skipInvocation>
									<streamLogs>true</streamLogs>
								</configuration>
							</execution>
						</executions>
					</plugin>
					<plugin>
						<groupId>org.apache.maven.plugins</groupId>
						<artifactId>maven-antrun-plugin</artifactId>
						<executions>
							<execution>
								<id>cleanup-local-integration-repo</id>
								<phase>pre-integration-test</phase>
								<goals>
									<goal>run</goal>
								</goals>
								<configuration>
									<target>
										<replaceregexp match="\$\{revision\}" replace="${project.version}"
											flags="g" byline="true">
											<fileset
												dir="${project.build.directory}/local-repo/org/springframework/boot/"
												includes="**/*.pom" />
										</replaceregexp>
									</target>
								</configuration>
							</execution>
						</executions>
					</plugin>
				</plugins>
			</build>
		</profile>
		<profile>
			<id>full</id>
			<activation>
				<property>
					<name>full</name>
				</property>
			</activation>
			<build>
				<plugins>
					<plugin>
						<groupId>org.apache.maven.plugins</groupId>
						<artifactId>maven-site-plugin</artifactId>
						<executions>
							<execution>
								<id>generate-site</id>
								<goals>
									<goal>jar</goal>
								</goals>
							</execution>
						</executions>
					</plugin>
					<plugin>
						<groupId>org.apache.maven.plugins</groupId>
						<artifactId>maven-invoker-plugin</artifactId>
						<configuration>
							<localRepositoryPath>${project.build.directory}/local-repo</localRepositoryPath>
						</configuration>
						<executions>
							<execution>
								<id>prepare-integration-test</id>
								<phase>pre-integration-test</phase>
								<goals>
									<goal>install</goal>
								</goals>
							</execution>
							<execution>
								<id>integration-test</id>
								<goals>
									<goal>run</goal>
								</goals>
								<configuration>
									<cloneProjectsTo>${project.build.directory}/it</cloneProjectsTo>
									<settingsFile>src/it/settings.xml</settingsFile>
									<postBuildHookScript>verify</postBuildHookScript>
									<addTestClassPath>true</addTestClassPath>
									<skipInvocation>${skipTests}</skipInvocation>
									<streamLogs>true</streamLogs>
								</configuration>
							</execution>
						</executions>
					</plugin>
					<plugin>
						<groupId>org.apache.maven.plugins</groupId>
						<artifactId>maven-antrun-plugin</artifactId>
						<executions>
							<execution>
								<id>cleanup-local-integration-repo</id>
								<phase>pre-integration-test</phase>
								<goals>
									<goal>run</goal>
								</goals>
								<configuration>
									<target>
										<replaceregexp match="\$\{revision\}" replace="${project.version}"
											flags="g" byline="true">
											<fileset
												dir="${project.build.directory}/local-repo/org/springframework/boot/"
												includes="**/*.pom" />
										</replaceregexp>
									</target>
								</configuration>
							</execution>
						</executions>
					</plugin>
				</plugins>
			</build>
			<reporting>
				<plugins>
					<plugin>
						<groupId>org.apache.maven.plugins</groupId>
						<artifactId>maven-plugin-plugin</artifactId>
					</plugin>
					<plugin>
						<groupId>org.apache.maven.plugins</groupId>
						<artifactId>maven-project-info-reports-plugin</artifactId>
						<version>2.9</version>
						<reportSets>
							<reportSet>
								<reports>
									<report>index</report>
									<report>cim</report>
									<report>issue-tracking</report>
									<report>license</report>
									<report>scm</report>
								</reports>
							</reportSet>
						</reportSets>
						<configuration>
							<linkOnly>true</linkOnly>
						</configuration>
					</plugin>
				</plugins>
			</reporting>
		</profile>
	</profiles>
</project>
