<?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>
        <groupId>com.atlassian.servicedesk</groupId>
        <artifactId>servicedesk-tests-parent</artifactId>
        <version>1000.211.0</version>
    </parent>
    <modelVersion>4.0.0</modelVersion>

    <artifactId>servicedesk-conditions-plugin</artifactId>
    <name>Service Desk Example SLA Conditions Plugin</name>
    <packaging>atlassian-plugin</packaging>


    <dependencies>
        <!-- Service desk -->
        <dependency>
            <groupId>com.atlassian.servicedesk</groupId>
            <artifactId>jira-servicedesk-api</artifactId>
            <version>${project.version}</version>
            <scope>provided</scope>
        </dependency>
        <dependency>
            <groupId>com.atlassian.jira</groupId>
            <artifactId>jira-api</artifactId>
            <scope>provided</scope>
        </dependency>
        <dependency>
            <groupId>org.springframework</groupId>
            <artifactId>spring-beans</artifactId>
            <scope>provided</scope>
        </dependency>
        <dependency>
            <groupId>org.springframework</groupId>
            <artifactId>spring-context</artifactId>
            <scope>provided</scope>
        </dependency>
        <dependency>
            <groupId>commons-lang</groupId>
            <artifactId>commons-lang</artifactId>
            <scope>provided</scope>
        </dependency>
        <dependency>
            <groupId>joda-time</groupId>
            <artifactId>joda-time</artifactId>
            <scope>provided</scope>
        </dependency>
        <dependency>
            <groupId>com.google.guava</groupId>
            <artifactId>guava</artifactId>
            <scope>provided</scope>
        </dependency>
    </dependencies>

    <build>
        <resources>
            <resource>
                <directory>src/main/resources</directory>
                <!-- don't copy project templates (as they have to be zipped up -->
                <excludes>
                    <exclude>project-templates/**</exclude>
                </excludes>
            </resource>
        </resources>
        <plugins>

            <plugin>
                <groupId>org.codehaus.mojo</groupId>
                <artifactId>buildnumber-maven-plugin</artifactId>
                <version>1.1</version>
                <executions>
                    <execution>
                        <phase>validate</phase>
                        <goals>
                            <goal>create</goal>
                        </goals>
                    </execution>
                </executions>
                <configuration>
                    <shortRevisionLength>8</shortRevisionLength>
                    <revisionOnScmFailure>unknown</revisionOnScmFailure>
                </configuration>
            </plugin>

            <!--
            This config is the guy who builds most of the JIRA plugin magic from our day to day point of view

            Be deliberate about what you change here and why you do it

            -->
            <plugin>
                <groupId>com.atlassian.maven.plugins</groupId>
                <artifactId>maven-jira-plugin</artifactId>
                <extensions>true</extensions>
                <configuration>
                    <productVersion>${jira.version}</productVersion>
                    <productDataVersion>${jira.version}</productDataVersion>
                    <enableFastdev>false</enableFastdev>
                    <log4jProperties>src/test/resources/log4j.properties</log4jProperties>
                    <systemPropertyVariables>
                        <xvfb.enable>${xvfb.enable}</xvfb.enable>
                    </systemPropertyVariables>
                    <jvmArgs>${jvmargs} ${jrebel.agent}</jvmArgs>
                    <instructions>
                        <Bundle-SymbolicName>com.atlassian.jira.plugins.servicedesk.conditions</Bundle-SymbolicName>
                        <Private-Package>
                        </Private-Package>

                        <!--optionals first, in alphabetic order, followed by mandatories, followed by exclusions, in alphabetic order-->
                        <Import-Package>
                            *
                        </Import-Package>
                        <Spring-Context>*</Spring-Context>
                    </instructions>


                    <!--These are put there via AMPs - since AMPS doesnt do OBRs then we need to repeat plugins here-->
                    <pluginArtifacts>
                    </pluginArtifacts>

                    <pluginDependencies>
                    </pluginDependencies>

                </configuration>
            </plugin>
        </plugins>
        <pluginManagement>
            <plugins>
                <plugin>
                    <artifactId>maven-surefire-plugin</artifactId>
                    <configuration>
                        <excludes>
                            <exclude>**/*$*</exclude>
                            <exclude>it/**</exclude>
                        </excludes>
                    </configuration>
                </plugin>
                <plugin>
                    <groupId>com.atlassian.maven.plugins</groupId>
                    <artifactId>maven-amps-dispatcher-plugin</artifactId>
                    <version>${amps.version}</version>
                </plugin>
            </plugins>
        </pluginManagement>
    </build>
    <properties>
        <jrebel.agent><!-- see jrebel profile to enable --></jrebel.agent>
        <jvmargs><!-- placeholeder for -jvmargs param from atlas-debug  --></jvmargs>
    </properties>

</project>
