<?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">
    <parent>
        <artifactId>jira-issue-nav-plugin-parent</artifactId>
        <groupId>com.atlassian.jira</groupId>
        <version>7.0.23</version>
    </parent>
    <modelVersion>4.0.0</modelVersion>

    <packaging>atlassian-plugin</packaging>
    <artifactId>jira-issue-nav-components</artifactId>

    <name>Atlassian JIRA - Plugins - Issue Search Components</name>
    <description>Provides components for viewing and searching for issues</description>

    <build>
        <pluginManagement>
            <plugins>
                <plugin>
                    <groupId>org.twdata.maven</groupId>
                    <artifactId>cargo-maven2-plugin</artifactId>
                    <version>1.0-beta-2-db2</version>
                </plugin>
                <plugin>
                    <groupId>com.atlassian.maven.plugins</groupId>
                    <artifactId>pseudo-loc-maven-plugin</artifactId>
                    <version>1.1</version>
                </plugin>
                <plugin>
                    <artifactId>maven-failsafe-plugin</artifactId>
                    <version>2.9</version>
                </plugin>
            </plugins>
        </pluginManagement>
        <plugins>
            <plugin>
                <groupId>com.atlassian.lesscss</groupId>
                <artifactId>lesscss-maven-plugin</artifactId>
                <executions>
                    <execution>
                        <id>compile-less</id>
                        <phase>process-resources</phase>
                        <goals>
                            <goal>compile</goal>
                        </goals>
                    </execution>
                </executions>
            </plugin>
            <plugin>
                <groupId>org.apache.maven.plugins</groupId>
                <artifactId>maven-surefire-plugin</artifactId>
                <version>2.16</version>
                <configuration>
                    <excludes>
                        <exclude>**/*$*</exclude>
                        <exclude>it/**</exclude>
                    </excludes>
                    <skipTests>${skipTests}</skipTests>
                </configuration>
            </plugin>
            <plugin>
                <groupId>com.atlassian.maven.plugins</groupId>
                <artifactId>maven-jira-plugin</artifactId>
                <extensions>true</extensions>
                <configuration>
                    <containerId>tomcat7x</containerId>
                    <enableFastdev>${enable.fastdev}</enableFastdev>
                    <systemPropertyVariables>
                        <atlassian.dev.mode>${ka.devmode}</atlassian.dev.mode>
                        <jira.websudo.is.disabled>true</jira.websudo.is.disabled>
                        <atlassian.mail.senddisabled>true</atlassian.mail.senddisabled>
                        <atlassian.mail.fetchdisabled>true</atlassian.mail.fetchdisabled>
                        <xvfb.enable>${xvfb.enable}</xvfb.enable>
                        <webdriver.browser>${webdriver.browser}</webdriver.browser>
                        <jira.qunit.testoutput.location>${project.build.directory}/surefire-reports</jira.qunit.testoutput.location>
                    </systemPropertyVariables>
                    <skipITs>${skipITs}</skipITs>
                    <skipManifestValidation>true</skipManifestValidation>
                    <productVersion>${jira.version}</productVersion>
                    <productDataVersion>${jira.data.version}</productDataVersion>
                    <compressResources>${compressResources}</compressResources>
                    <pluginArtifacts>
                        <pluginArtifact>
                            <groupId>com.atlassian</groupId>
                            <artifactId>atl-docco</artifactId>
                            <version>0.11</version>
                        </pluginArtifact>
                        <pluginArtifact>
                            <groupId>com.atlassian.qunit</groupId>
                            <artifactId>atlassian-qunit-plugin</artifactId>
                            <version>${atlassian.qunit.plugin.version}</version>
                        </pluginArtifact>
                        <pluginArtifact>
                            <groupId>com.atlassian.jira</groupId>
                            <artifactId>jira-func-test-plugin</artifactId>
                            <version>${jira.version}</version>
                        </pluginArtifact>
                        <pluginArtifact>
                            <groupId>com.atlassian.jira.tests</groupId>
                            <artifactId>jira-testkit-plugin</artifactId>
                            <version>${testkit.version}</version>
                        </pluginArtifact>
                        <pluginArtifact>
                            <groupId>com.atlassian.jira</groupId>
                            <artifactId>jira-issue-nav-plugin</artifactId>
                            <version>${project.version}</version>
                        </pluginArtifact>
                    </pluginArtifacts>
                    <instructions>
                        <Atlassian-Plugin-Key>${project.groupId}.${project.artifactId}</Atlassian-Plugin-Key>
                        <Export-Package>
                            com.atlassian.jira.components.*
                        </Export-Package>
                        <Import-Package>
                            com.atlassian.jira.rest*;version="[6.0,8)",
                            org.springframework.beans*;version="2.5",
                            org.springframework.context*;version="2.5",
                            org.springframework.stereotype*;version="2.5",
                            org.springframework.util*;version="2.5",
                            com.atlassian.sal.api*;resolution:=optional;version="2.10",
                            *;resolution:=optional
                        </Import-Package>
                        <Spring-Context>*</Spring-Context>
                    </instructions>
                </configuration>
            </plugin>
            <plugin>
                <groupId>org.apache.maven.plugins</groupId>
                <artifactId>maven-jar-plugin</artifactId>
                <version>2.4</version>
                <executions>
                    <execution>
                        <goals>
                            <goal>test-jar</goal>
                        </goals>
                        <configuration>
                            <forceCreation>true</forceCreation>
                        </configuration>
                    </execution>
                </executions>
            </plugin>
        </plugins>
    </build>
    <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.abbrev}, 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>
                                <phase>validate</phase>
                                <goals>
                                    <goal>create</goal>
                                    <goal>create-timestamp</goal>
                                </goals>
                            </execution>
                        </executions>
                        <configuration>
                            <!-- set the Git commit id -->
                            <buildNumberPropertyName>git.commit.id.abbrev</buildNumberPropertyName>
                            <shortRevisionLength>7</shortRevisionLength>
                            <revisionOnScmFailure>unknown</revisionOnScmFailure>

                            <!-- also set the build timestamp -->
                            <timestampFormat>yyyy-MM-dd'T'HH:mm:ssZ</timestampFormat>
                            <timestampPropertyName>maven.build.timestamp</timestampPropertyName>
                        </configuration>
                    </plugin>
                </plugins>
            </build>
        </profile>
        <profile>
            <id>pseudo-loc</id>
            <activation>
                <property>
                    <name>jira.acceptance.tests</name>
                    <value>!true</value>
                </property>
            </activation>
            <build>
                <plugins>
                    <plugin>
                        <groupId>com.atlassian.maven.plugins</groupId>
                        <artifactId>pseudo-loc-maven-plugin</artifactId>
                        <executions>
                            <execution>
                                <id>pseudo-loc</id>
                                <phase>generate-sources</phase>
                                <goals>
                                    <goal>pseudo-loc</goal>
                                </goals>
                            </execution>
                        </executions>
                        <configuration>
                            <sourceLocale>en_UK</sourceLocale>
                            <targetLocale>en_AQ</targetLocale>
                            <pseudoLocaliseActions>
                                <pseudoLocaliseAction>
                                    <source>src/main/resources/i18n.properties</source>
                                    <target>src/main/resources/i18n_{loc}.properties</target>
                                </pseudoLocaliseAction>
                            </pseudoLocaliseActions>
                        </configuration>
                    </plugin>
                </plugins>
            </build>
        </profile>
    </profiles>
    <dependencies>
        <dependency>
            <groupId>com.atlassian.jira</groupId>
            <artifactId>jira-api</artifactId>
            <version>${jira.version}</version>
            <scope>provided</scope>
        </dependency>
        <dependency>
            <groupId>com.atlassian.jira</groupId>
            <artifactId>jira-rest-api</artifactId>
            <version>${jira.version}</version>
            <scope>provided</scope>
        </dependency>
        <dependency>
            <groupId>com.atlassian.jira</groupId>
            <artifactId>jira-core</artifactId>
            <version>${jira.version}</version>
            <scope>provided</scope>
        </dependency>
        <dependency>
            <groupId>com.atlassian.jira</groupId>
            <artifactId>jira-rest-plugin</artifactId>
            <version>${jira.version}</version>
            <scope>provided</scope>
        </dependency>

        <dependency>
            <groupId>com.atlassian.jira</groupId>
            <artifactId>jira-tests</artifactId>
            <version>${jira.version}</version>
            <scope>test</scope>
        </dependency>

        <dependency>
            <groupId>com.atlassian.analytics</groupId>
            <artifactId>analytics-api</artifactId>
            <version>${analytics.api.version}</version>
            <scope>provided</scope>
        </dependency>


        <dependency>
            <groupId>com.atlassian.plugins.rest</groupId>
            <artifactId>atlassian-rest-common</artifactId>
            <version>${rest.version}</version>
            <scope>provided</scope>
        </dependency>

        <dependency>
            <groupId>javax.servlet</groupId>
            <artifactId>servlet-api</artifactId>
            <version>2.3</version>
            <scope>provided</scope>
        </dependency>

        <dependency>
            <groupId>junit</groupId>
            <artifactId>junit</artifactId>
            <version>4.10</version>
            <scope>test</scope>
        </dependency>

        <dependency>
            <groupId>com.atlassian.jira</groupId>
            <artifactId>atlassian-jira-pageobjects</artifactId>
            <scope>test</scope>
        </dependency>
        <dependency> <!-- needed by selenium client, but somehow not pulled in by jira-pageobjects -->
            <groupId>org.apache.httpcomponents</groupId>
            <artifactId>httpclient</artifactId>
            <scope>test</scope>
        </dependency>
        <dependency>
            <groupId>com.atlassian.qunit</groupId>
            <artifactId>atlassian-qunit-plugin-util</artifactId>
            <version>${atlassian.qunit.plugin.version}</version>
            <scope>test</scope>
        </dependency>
        <dependency>
            <groupId>com.atlassian.jira</groupId>
            <artifactId>ka-func-test-framework</artifactId>
            <version>${project.version}</version>
            <scope>test</scope>
        </dependency>

        <!-- jira-testkit-client is required by nimble-func-tests -->
        <dependency>
            <groupId>com.atlassian.jira.tests</groupId>
            <artifactId>jira-testkit-client</artifactId>
            <scope>test</scope>
        </dependency>
        <dependency>
            <groupId>com.atlassian.jira</groupId>
            <artifactId>jira-nimble-func-tests</artifactId>
            <version>0.2.1</version>
            <scope>test</scope>
        </dependency>

        <dependency>
            <groupId>javax.inject</groupId>
            <artifactId>javax.inject</artifactId>
            <version>1</version>
            <scope>provided</scope>
        </dependency>

        <dependency>
            <groupId>commons-codec</groupId>
            <artifactId>commons-codec</artifactId>
            <version>1.4</version>
            <scope>provided</scope>
        </dependency>

        <dependency>
            <groupId>com.atlassian.plugin</groupId>
            <artifactId>atlassian-spring-scanner-annotation</artifactId>
        </dependency>
        <dependency>
            <groupId>com.atlassian.plugin</groupId>
            <artifactId>atlassian-spring-scanner-processor</artifactId>
        </dependency>
        <dependency>
            <groupId>com.atlassian.plugin</groupId>
            <artifactId>atlassian-spring-scanner-runtime</artifactId>
        </dependency>

    </dependencies>
</project>
