<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>name.valery1707.kaitai</groupId>
	<artifactId>kaitai-maven-plugin</artifactId>
	<version>0.1.4</version>
	<packaging>maven-plugin</packaging>

	<name>Kaitai Maven Plugin</name>
	<description>Maven plugin for [Kaitai](http://kaitai.io/): declarative language to generate binary data parsers
	</description>
	<url>https://github.com/valery1707/kaitai-maven-plugin</url>
	<inceptionYear>2018</inceptionYear>

	<licenses>
		<license>
			<name>MIT License</name>
			<url>http://opensource.org/licenses/MIT</url>
			<distribution>repo</distribution>
		</license>
	</licenses>

	<scm>
		<url>https://github.com/valery1707/kaitai-maven-plugin</url>
		<connection>scm:git:https://github.com/valery1707/kaitai-maven-plugin</connection>
		<developerConnection>scm:git|git@github.com:valery1707/kaitai-maven-plugin.git</developerConnection>
	</scm>
	<issueManagement>
		<system>GitHub</system>
		<url>https://github.com/valery1707/kaitai-maven-plugin</url>
	</issueManagement>

	<developers>
		<developer>
			<name>Valeriy Vyrva</name>
			<email>valery1707@gmail.com</email>
			<timezone>+3</timezone>
			<roles>
				<role>Founder</role>
				<role>Developer</role>
			</roles>
		</developer>
	</developers>

	<properties>
		<project.encoding>UTF-8</project.encoding>
		<project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
		<project.reporting.outputEncoding>UTF-8</project.reporting.outputEncoding>
		<java.version>1.7</java.version>
		<maven.compiler.source>${java.version}</maven.compiler.source>
		<maven.compiler.target>${java.version}</maven.compiler.target>
	</properties>

	<dependencies>
		<!--Provided-->
		<dependency>
			<groupId>org.apache.maven</groupId>
			<artifactId>maven-core</artifactId>
			<version>3.5.0</version>
			<scope>provided</scope>
		</dependency>
		<dependency>
			<groupId>org.apache.maven</groupId>
			<artifactId>maven-plugin-api</artifactId>
			<version>3.5.0</version>
			<scope>provided</scope>
		</dependency>
		<dependency>
			<groupId>org.apache.maven.plugin-tools</groupId>
			<artifactId>maven-plugin-annotations</artifactId>
			<version>3.5</version>
			<scope>provided</scope>
		</dependency>
		<dependency>
			<groupId>org.codehaus.plexus</groupId>
			<artifactId>plexus-utils</artifactId>
			<version>3.1.0</version>
			<scope>provided</scope>
		</dependency>

		<!--Compile-->
		<dependency>
			<groupId>commons-io</groupId>
			<artifactId>commons-io</artifactId>
			<version>2.6</version>
		</dependency>
		<dependency>
			<groupId>org.apache.commons</groupId>
			<artifactId>commons-lang3</artifactId>
			<version>3.5</version>
		</dependency>
		<dependency>
			<groupId>org.buildobjects</groupId>
			<artifactId>jproc</artifactId>
			<version>2.2.2</version>
		</dependency>
		<dependency>
			<groupId>org.slf4j</groupId>
			<artifactId>slf4j-api</artifactId>
			<version>1.7.25</version>
		</dependency>
		<dependency>
			<groupId>com.jcabi</groupId>
			<artifactId>jcabi-maven-slf4j</artifactId>
			<version>0.9</version>
		</dependency>

		<!--Test-->
		<dependency>
			<groupId>junit</groupId>
			<artifactId>junit</artifactId>
			<version>4.12</version>
			<scope>test</scope>
		</dependency>
		<dependency>
			<groupId>org.assertj</groupId>
			<artifactId>assertj-core</artifactId>
			<version>2.9.0</version>
			<scope>test</scope>
		</dependency>
		<dependency>
			<groupId>com.github.marschall</groupId>
			<artifactId>memoryfilesystem</artifactId>
			<version>1.2.0</version>
			<scope>test</scope>
		</dependency>
		<dependency>
			<groupId>commons-codec</groupId>
			<artifactId>commons-codec</artifactId>
			<version>1.11</version>
			<scope>test</scope>
		</dependency>
	</dependencies>

	<build>
		<plugins>
			<plugin>
				<groupId>org.apache.maven.plugins</groupId>
				<artifactId>maven-plugin-plugin</artifactId>
				<version>3.5</version>
				<configuration>
					<goalPrefix>kaitai</goalPrefix>
					<skipErrorNoDescriptorsFound>true</skipErrorNoDescriptorsFound>
				</configuration>
				<executions>
					<execution>
						<id>mojo-descriptor</id>
						<goals>
							<goal>descriptor</goal>
						</goals>
					</execution>
					<execution>
						<id>help-goal</id>
						<goals>
							<goal>helpmojo</goal>
						</goals>
					</execution>
				</executions>
			</plugin>

			<plugin>
				<groupId>org.codehaus.mojo</groupId>
				<artifactId>versions-maven-plugin</artifactId>
				<version>2.3</version>
				<configuration>
					<generateBackupPoms>false</generateBackupPoms>
				</configuration>
			</plugin>

			<plugin>
				<groupId>org.apache.maven.plugins</groupId>
				<artifactId>maven-checkstyle-plugin</artifactId>
				<version>3.0.0</version>
				<executions>
					<execution>
						<id>checkstyle</id>
						<phase>validate</phase>
						<goals>
							<goal>check</goal>
						</goals>
					</execution>
				</executions>
				<dependencies>
					<dependency>
						<groupId>com.puppycrawl.tools</groupId>
						<artifactId>checkstyle</artifactId>
						<version>8.16</version>
					</dependency>
				</dependencies>
				<configuration>
					<configLocation>.checkstyle.xml</configLocation>
					<encoding>UTF-8</encoding>
					<consoleOutput>true</consoleOutput>
					<failsOnError>true</failsOnError>
				</configuration>
			</plugin>
		</plugins>
	</build>

	<profiles>
		<profile>
			<id>run-its</id>
			<build>

				<plugins>
					<plugin>
						<groupId>org.apache.maven.plugins</groupId>
						<artifactId>maven-invoker-plugin</artifactId>
						<version>3.0.1</version>
						<configuration>
							<debug>true</debug>
							<cloneProjectsTo>${project.build.directory}/it</cloneProjectsTo>
							<pomIncludes>
								<pomInclude>*/pom.xml</pomInclude>
							</pomIncludes>
							<postBuildHookScript>verify</postBuildHookScript>
							<localRepositoryPath>${project.build.directory}/local-repo</localRepositoryPath>
							<settingsFile>src/it/settings.xml</settingsFile>
							<goals>
								<goal>clean</goal>
								<goal>test-compile</goal>
								<goal>test</goal>
							</goals>
						</configuration>
						<executions>
							<execution>
								<id>integration-test</id>
								<goals>
									<goal>install</goal>
									<goal>integration-test</goal>
									<goal>verify</goal>
								</goals>
							</execution>
						</executions>
					</plugin>
				</plugins>

			</build>
		</profile>

		<profile>
			<!--http://central.sonatype.org/pages/apache-maven.html-->
			<id>release</id>
			<build>
				<plugins>
					<plugin>
						<groupId>org.apache.maven.plugins</groupId>
						<artifactId>maven-source-plugin</artifactId>
						<version>3.0.1</version>
						<executions>
							<execution>
								<id>attach-sources</id>
								<goals>
									<goal>jar-no-fork</goal>
								</goals>
							</execution>
						</executions>
					</plugin>
					<plugin>
						<groupId>org.apache.maven.plugins</groupId>
						<artifactId>maven-javadoc-plugin</artifactId>
						<version>2.10.4</version>
						<executions>
							<execution>
								<id>attach-javadocs</id>
								<goals>
									<goal>jar</goal>
								</goals>
							</execution>
						</executions>
					</plugin>

					<plugin>
						<groupId>org.apache.maven.plugins</groupId>
						<artifactId>maven-gpg-plugin</artifactId>
						<version>1.6</version>
						<executions>
							<execution>
								<id>sign-artifacts</id>
								<phase>verify</phase>
								<goals>
									<goal>sign</goal>
								</goals>
							</execution>
						</executions>
					</plugin>

					<plugin>
						<artifactId>maven-deploy-plugin</artifactId>
						<version>2.8.2</version>
						<configuration>
							<skip>true</skip>
						</configuration>
					</plugin>
					<plugin>
						<groupId>org.sonatype.plugins</groupId>
						<artifactId>nexus-staging-maven-plugin</artifactId>
						<version>1.6.8</version>
						<extensions>true</extensions>
						<configuration>
							<serverId>oss.sonatype.org</serverId>
							<nexusUrl>https://oss.sonatype.org/</nexusUrl>
							<description>${project.version}</description>
						</configuration>
						<executions>
							<execution>
								<id>deploy-to-sonatype</id>
								<phase>deploy</phase>
								<goals>
									<goal>deploy</goal>
									<goal>release</goal>
								</goals>
							</execution>
						</executions>
					</plugin>

					<plugin>
						<groupId>de.jutzig</groupId>
						<artifactId>github-release-plugin</artifactId>
						<version>1.2.0</version>
						<configuration>
							<serverId>github</serverId>
							<description>${github.description}</description>
							<releaseName>${github.releaseName}</releaseName>
							<tag>${github.tag}</tag>
							<fileSets>
								<fileSet>
									<directory>${project.basedir}</directory>
									<includes>
										<include>**/kaitai-*.jar</include>
										<include>**/kaitai-*.pom</include>
										<include>**/kaitai-*.asc</include>
									</includes>
									<excludes>
										<exclude>**/kaitai-*-test-*.*</exclude>
										<exclude>local-repo</exclude>
									</excludes>
								</fileSet>
							</fileSets>
						</configuration>
					</plugin>
				</plugins>
			</build>
		</profile>
	</profiles>

	<distributionManagement>
		<snapshotRepository>
			<id>oss.sonatype.org</id>
			<url>https://oss.sonatype.org/content/repositories/snapshots</url>
		</snapshotRepository>
		<repository>
			<id>oss.sonatype.org</id>
			<url>https://oss.sonatype.org/service/local/staging/deploy/maven2/</url>
		</repository>
	</distributionManagement>
</project>
