<?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>

	<groupId>com.github.jaxb-xew-plugin</groupId>
	<artifactId>jaxb-xew-plugin</artifactId>
	<version>2.1</version>
	<packaging>jar</packaging>

	<name>JAXB @XmlElementWrapper Plugin</name>
	<inceptionYear>2022</inceptionYear>
	<description>This JAXB plugin utilizes the power of @XmlElementWrapper annotation. Originally xjc trends to create wrapper classes which are the containers for collections. This plugin goes through all properties to find ones which can be represented in the model in more optimal way.</description>
	<url>https://github.com/dmak/jaxb-xew-plugin</url>

	<scm>
		<url>https://github.com/dmak/jaxb-xew-plugin</url>
		<connection>scm:git:https://github.com/dmak/jaxb-xew-plugin.git</connection>
		<developerConnection>scm:git:https://dmak@github.com/dmak/jaxb-xew-plugin.git</developerConnection>
		<tag>release-2.1</tag>
	</scm>

	<distributionManagement>
		<snapshotRepository>
			<id>sonatype-nexus-snapshots</id>
			<name>Sonatype Nexus Snapshots</name>
			<url>https://oss.sonatype.org/content/repositories/snapshots/</url>
		</snapshotRepository>
		<repository>
			<id>sonatype-nexus-staging</id>
			<name>Nexus Release Repository</name>
			<url>https://oss.sonatype.org/service/local/staging/deploy/maven2/</url>
		</repository>
	</distributionManagement>

	<issueManagement>
		<system>GitHub</system>
		<url>https://github.com/dmak/jaxb-xew-plugin/issues</url>
	</issueManagement>

	<licenses>
		<license>
			<name>LGPLv3 License</name>
			<url>https://www.gnu.org/licenses/lgpl-3.0.html</url>
			<distribution>repo</distribution>
		</license>
	</licenses>

	<properties>
		<jaxb-api.version>3.0.1</jaxb-api.version>
		<jaxb-core.version>3.0.1</jaxb-core.version>

		<maven.compiler.source>1.8</maven.compiler.source>
		<maven.compiler.target>1.8</maven.compiler.target>
		<project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
	</properties>

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

			<build>
				<pluginManagement>
					<plugins>
						<plugin>
							<artifactId>maven-release-plugin</artifactId>
							<version>2.5.3</version>
							<configuration>
								<tagNameFormat>release-@{project.version}</tagNameFormat>
							</configuration>
						</plugin>
						<plugin>
							<!-- This plugin is suppressed by nexus-staging-maven-plugin but we tune it just in case. -->
							<artifactId>maven-deploy-plugin</artifactId>
							<version>2.8.2</version>
							<configuration>
								<retryFailedDeploymentCount>3</retryFailedDeploymentCount>
							</configuration>
						</plugin>
						<plugin>
							<groupId>org.sonatype.plugins</groupId>
							<artifactId>nexus-staging-maven-plugin</artifactId>
							<version>1.6.13</version>
							<extensions>true</extensions>
							<configuration>
								<serverId>sonatype-nexus-staging</serverId>
								<nexusUrl>https://oss.sonatype.org/</nexusUrl>
								<autoReleaseAfterClose>true</autoReleaseAfterClose>
							</configuration>
						</plugin>
					</plugins>
				</pluginManagement>

				<plugins>
					<plugin>
						<groupId>org.apache.maven.plugins</groupId>
						<artifactId>maven-gpg-plugin</artifactId>
						<executions>
							<execution>
								<id>sign-artifacts</id>
								<phase>verify</phase>
								<goals>
									<goal>sign</goal>
								</goals>
							</execution>
						</executions>
					</plugin>
					<plugin>
						<!-- This plugin suppresses maven-deploy-plugin and binds itself to deploy phase. -->
						<groupId>org.sonatype.plugins</groupId>
						<artifactId>nexus-staging-maven-plugin</artifactId>
					</plugin>
				</plugins>
			</build>
		</profile>
	</profiles>

	<developers>
		<developer>
			<name>Bjarne Hansen</name>
			<email>bjarne@conspicio.dk</email>
			<roles>
				<role>developer</role>
			</roles>
		</developer>
		<developer>
			<name>Dmitry Katsubo</name>
			<email>dmitry.katsubo@gmail.com</email>
			<url>https://www.linkedin.com/in/dkatsubo</url>
			<roles>
				<role>developer</role>
			</roles>
		</developer>
	</developers>

	<dependencyManagement>
		<dependencies>
			<!-- Remove this dependency management after https://github.com/highsource/jaxb2-basics/pull/119 is resolved -->
			<dependency>
				<groupId>commons-beanutils</groupId>
				<artifactId>commons-beanutils</artifactId>
				<version>1.9.4</version>
			</dependency>
		</dependencies>
	</dependencyManagement>

	<dependencies>
		<dependency>
			<groupId>jakarta.xml.bind</groupId>
			<artifactId>jakarta.xml.bind-api</artifactId>
			<version>${jaxb-api.version}</version>
		</dependency>
		<dependency>
			<groupId>org.glassfish.jaxb</groupId>
			<artifactId>jaxb-jxc</artifactId>
			<version>${jaxb-core.version}</version>
		</dependency>
		<dependency>
			<groupId>org.glassfish.jaxb</groupId>
			<artifactId>jaxb-runtime</artifactId>
			<version>${jaxb-core.version}</version>
		</dependency>

		<dependency>
			<groupId>commons-logging</groupId>
			<artifactId>commons-logging</artifactId>
			<version>1.2</version>
		</dependency>
		<dependency>
			<groupId>org.apache.commons</groupId>
			<artifactId>commons-lang3</artifactId>
			<version>3.12.0</version>
		</dependency>

		<dependency>
			<groupId>codes.rafael.jaxb2_commons</groupId>
			<artifactId>jaxb2-basics-tools</artifactId>
			<version>3.0.0</version>
			<exclusions>
				<exclusion>
					<groupId>org.slf4j</groupId>
					<artifactId>jcl-over-slf4j</artifactId>
				</exclusion>
			</exclusions>
		</dependency>

		<dependency>
			<groupId>org.junit.jupiter</groupId>
			<artifactId>junit-jupiter</artifactId>
			<version>5.9.2</version>
			<scope>test</scope>
		</dependency>
		<dependency>
			<groupId>org.assertj</groupId>
			<artifactId>assertj-core</artifactId>
			<version>3.24.2</version>
		</dependency>
		<dependency>
			<groupId>org.xmlunit</groupId>
			<artifactId>xmlunit-assertj3</artifactId>
			<version>2.9.1</version>
			<scope>test</scope>
		</dependency>
		<dependency>
			<groupId>org.xmlunit</groupId>
			<artifactId>xmlunit-jakarta-jaxb-impl</artifactId>
			<version>2.9.1</version>
			<scope>test</scope>
		</dependency>
		<dependency>
			<groupId>io.earcam.wrapped</groupId>
			<artifactId>jdk.compiler</artifactId>
			<version>1.8.132</version>
			<scope>test</scope>
		</dependency>
	</dependencies>

	<build>
		<pluginManagement>
			<plugins>
				<plugin>
					<artifactId>maven-surefire-plugin</artifactId>
					<version>2.22.2</version>
				</plugin>
				<plugin>
					<groupId>org.apache.maven.plugins</groupId>
					<artifactId>maven-gpg-plugin</artifactId>
					<version>3.0.1</version>
					<configuration>
						<!-- Fix for "gpg: signing failed: Inappropriate ioctl for device", see https://gist.github.com/michaelajr/ff4693bce9fc20e5200b34683aa4ba51 and https://ru.stackoverflow.com/questions/791317/ -->
						<gpgArguments>
							<arg>--pinentry-mode</arg>
							<arg>loopback</arg>
						</gpgArguments>
					</configuration>
				</plugin>
			</plugins>
		</pluginManagement>

		<plugins>
			<plugin>
				<groupId>org.jacoco</groupId>
				<artifactId>jacoco-maven-plugin</artifactId>
				<version>0.8.8</version>
				<executions>
					<execution>
						<id>prepare-agent</id>
						<goals>
							<goal>prepare-agent</goal>
						</goals>
					</execution>
					<execution>
						<id>create-report</id>
						<phase>test</phase>
						<goals>
							<goal>report</goal>
						</goals>
					</execution>
				</executions>
			</plugin>
		</plugins>
	</build>
</project>
