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

	<parent>
		<groupId>com.atlassian.pom</groupId>
		<artifactId>closedsource-pom</artifactId>
		<version>5.0.13</version>
	</parent>

    <scm>
        <connection>scm:git:ssh://git@stash.atlassian.com:7997/JIRASERVER/jira-project-templates-plugin.git</connection>
        <developerConnection>scm:git:ssh://git@stash.atlassian.com:7997/JIRASERVER/jira-project-templates-plugin.git</developerConnection>
        <url>https://stash.atlassian.com/projects/JIRASERVER/repos/jira-project-templates-plugin/browse</url>
      <tag>project-templates-parent-7.0.0</tag>
  </scm>

    <groupId>com.atlassian.jira.plugins</groupId>
    <artifactId>project-templates-parent</artifactId>
    <version>7.0.0</version>
	<packaging>pom</packaging>

    <licenses>
        <license>
            <name>Atlassian End User License</name>
            <url>https://www.atlassian.com/end-user-agreement/</url>
            <comments>Atlassian 3.0 End User License Agreement</comments>
        </license>
    </licenses>

    <name>Jira Project Templates</name>
	<description>Defines the different Jira Project Templates</description>
	<inceptionYear>2013</inceptionYear>

	<modules>
	    <module>project-templates-api</module>
	    <module>project-templates-pageobjects</module>
	    <module>project-templates-plugin</module>
	    <module>project-templates-samples</module>
        <module>jira-core-project-templates</module>
        <module>jira-core-project-templates-api</module>
        <module>project-templates-acceptance-tests</module>
    </modules>

    <properties>
        <project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
        <project.reporting.outputEncoding>UTF-8</project.reporting.outputEncoding>
        <jira.version>8.0.0-QR-20181002080151</jira.version>
        <jira.rest.version>3.2.11</jira.rest.version>
        <plugins.version>4.1.0</plugins.version>
        <jira.workflow.importer.version>1.1.20</jira.workflow.importer.version>
        <amps.version>6.2.8</amps.version>
        <plugin.testrunner.version>1.2.3</plugin.testrunner.version>
        <testkit.version>8.0.1-2b2193d1</testkit.version>
        <gson.version>2.2.2-atlassian-1</gson.version>
        <atlassian.qunit.plugin.version>1.0.4</atlassian.qunit.plugin.version>
        <atlassian.concurrent.version>2.6.2</atlassian.concurrent.version>
        <ao.version>1.4.0</ao.version>
        <slf4j.version>1.7.9</slf4j.version>
        <atlassian-plugin.description>${project.description}</atlassian-plugin.description>
        <maven.compiler.source>8</maven.compiler.source>
        <maven.compiler.target>8</maven.compiler.target>
        <pocketknife.version>3.0.3</pocketknife.version>
        <spring.version>4.1.6.RELEASE</spring.version>
        <spring.scanner.version>1.2.12</spring.scanner.version>
        <atlassian.json.version>0.9</atlassian.json.version>
        <jim.version>7.1.2</jim.version>
        <httpcore.version>4.4.1</httpcore.version>
    </properties>

    <build>
        <pluginManagement>
            <plugins>
                <plugin>
                    <groupId>net.sf.alchim</groupId>
                    <artifactId>yuicompressor-maven-plugin</artifactId>
                    <version>0.7.1</version>
                </plugin>
                <plugin>
                    <groupId>com.atlassian.maven.plugins</groupId>
                    <artifactId>maven-amps-plugin</artifactId>
                    <version>${amps.version}</version>
                </plugin>
                <plugin>
                    <groupId>com.atlassian.maven.plugins</groupId>
                    <artifactId>maven-amps-dispatcher-plugin</artifactId>
                    <version>${amps.version}</version>
                </plugin>
                <plugin>
                    <groupId>com.atlassian.maven.plugins</groupId>
                    <artifactId>maven-jira-plugin</artifactId>
                    <version>${amps.version}</version>
                    <extensions>true</extensions>
                    <configuration>
                        <!-- sensible defaults -->
                        <productVersion>${jira.version}</productVersion>
                        <productDataVersion>${jira.version}</productDataVersion>
                        <extractDependencies>false</extractDependencies>

                        <!-- disable AMPS bloat -->
                        <skipAllPrompts>true</skipAllPrompts>
                        <enableFastdev>false</enableFastdev>
                        <enableDevToolbox>false</enableDevToolbox>
                    </configuration>
                </plugin>
                <plugin>
                    <!-- use local checkout with Git -->
                    <artifactId>maven-release-plugin</artifactId>
                    <configuration>
                        <localCheckout>true</localCheckout>
                    </configuration>
                </plugin>
                <plugin>
                    <groupId>org.apache.maven.plugins</groupId>
                    <artifactId>maven-jar-plugin</artifactId>
                    <executions>
                        <execution>
                            <goals>
                                <goal>test-jar</goal>
                            </goals>
                        </execution>
                    </executions>
                </plugin>
                <plugin>
                    <groupId>org.apache.maven.plugins</groupId>
                    <artifactId>maven-surefire-plugin</artifactId>
                    <version>2.15</version>
                </plugin>
            </plugins>
        </pluginManagement>
    </build>

    <dependencyManagement>
        <dependencies>
            <dependency>
                <groupId>org.springframework</groupId>
                <artifactId>spring-beans</artifactId>
                <version>${spring.version}</version>
                <scope>provided</scope>
            </dependency>
            <dependency>
                <groupId>com.atlassian.plugin</groupId>
                <artifactId>atlassian-spring-scanner-annotation</artifactId>
                <version>${spring.scanner.version}</version>
                <scope>compile</scope>
            </dependency>
            <dependency>
                <groupId>com.atlassian.plugin</groupId>
                <artifactId>atlassian-spring-scanner-runtime</artifactId>
                <version>${spring.scanner.version}</version>
                <scope>compile</scope>
            </dependency>
        </dependencies>
    </dependencyManagement>

    <profiles>
        <profile> <!-- Used for snapshots so we don't have caching problems and know which git revision was used -->
            <id>stamp</id>
            <activation>
                <property>
                    <name>!skipCommitIdStamp</name>
                </property>
            </activation>
            <properties>
                <maven.build.timestamp.format>yyyy-MM-dd'T'HH:mm:ssZ</maven.build.timestamp.format>
                <!-- place the revision and build date in the plugin description -->
                <atlassian-plugin.description>${project.description} (rev: ${git.commit.id.short}, date: ${maven.build.timestamp})</atlassian-plugin.description>
            </properties>
            <build>
                <plugins>
                    <plugin>
                        <groupId>org.codehaus.mojo</groupId>
                        <artifactId>buildnumber-maven-plugin</artifactId>
                        <version>1.2</version>
                        <executions>
                            <execution>
                                <id>get-commit-id</id>
                                <phase>validate</phase>
                                <goals>
                                    <goal>create</goal>
                                    <goal>create-timestamp</goal>
                                </goals>
                                <configuration>
                                    <buildNumberPropertyName>git.commit.id.long</buildNumberPropertyName>
                                </configuration>
                            </execution>
                            <execution>
                                <id>get-short-commit-id</id>
                                <phase>validate</phase>
                                <goals>
                                    <goal>create</goal>
                                </goals>
                                <configuration>
                                    <buildNumberPropertyName>git.commit.id.short</buildNumberPropertyName>
                                    <shortRevisionLength>7</shortRevisionLength>
                                </configuration>
                            </execution>
                        </executions>
                        <configuration>
                            <!-- set the Git commit id -->
                            <revisionOnScmFailure>unknown</revisionOnScmFailure>
                            <getRevisionOnlyOnce>true</getRevisionOnlyOnce>

                            <!-- also set the build timestamp -->
                            <timestampFormat>yyyy-MM-dd'T'HH:mm:ssZ</timestampFormat>
                            <timestampPropertyName>maven.build.timestamp</timestampPropertyName>
                        </configuration>
                    </plugin>
                    <plugin>
                        <groupId>org.apache.maven.plugins</groupId>
                        <artifactId>maven-jar-plugin</artifactId>
                        <version>2.4</version>
                        <configuration>
                            <archive>
                                <manifestEntries>
                                    <Atlassian-Commit-Id>${git.commit.id.long}</Atlassian-Commit-Id>
                                </manifestEntries>
                            </archive>
                        </configuration>
                    </plugin>
                </plugins>
            </build>
        </profile>
    </profiles>

</project>
