<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.jira</groupId>
    <artifactId>jira-plugins</artifactId>
    <version>7.3.0-TEST-SOKEBASE-2</version>
  </parent>
  <artifactId>jira-reference-upgraded-plugin</artifactId>
  <name>Atlassian JIRA - Plugins - Development Only - Reference Upgraded Plugin</name>
  <description>JIRA plugin that contains reference implementations of the extension points in JIRA</description>
  <packaging>bundle</packaging>
  <build>
    <sourceDirectory>${project.build.directory}/generated-sources/jira-reference-plugin</sourceDirectory>
    <resources>
        <resource>
            <directory>${project.build.directory}/generated-sources/jira-reference-plugin</directory>
            <filtering>true</filtering>
            <includes>
                <include>**/atlassian-plugin.xml</include>
            </includes>
        </resource>
        <resource>
            <directory>${project.build.directory}/generated-sources/jira-reference-plugin</directory>
            <filtering>false</filtering>
            <excludes>
                <exclude>**/atlassian-plugin.xml</exclude>
                <exclude>**/*.java</exclude>
            </excludes>
        </resource>
    </resources>
    <plugins>
      <plugin>
        <groupId>org.apache.felix</groupId>
        <artifactId>maven-bundle-plugin</artifactId>
        <configuration>
          <instructions>
            <Bundle-SymbolicName>${atlassian.plugin.key}</Bundle-SymbolicName>
            <Bundle-Version>${reference.plugin.version}</Bundle-Version>
            <Export-Package>com.atlassian.jira.dev.reference.plugin.components.*</Export-Package>
            <Spring-Context>*;timeout:=60</Spring-Context>
          </instructions>
        </configuration>
      </plugin>
      <plugin>
        <groupId>org.twdata.maven</groupId>
        <artifactId>maven-cli-plugin</artifactId>
      </plugin>
      <plugin>
          <artifactId>maven-dependency-plugin</artifactId>
          <executions>
              <execution>
                  <id>unpack-sources</id>
                  <phase>generate-sources</phase>
                  <goals>
                      <goal>unpack-dependencies</goal>
                  </goals>
                  <configuration>
                      <includeArtifactIds>jira-reference-plugin</includeArtifactIds>
                      <outputDirectory>${project.build.directory}/generated-sources/jira-reference-plugin</outputDirectory>
                  </configuration>
              </execution>
          </executions>
      </plugin>
      <plugin>
          <artifactId>maven-antrun-plugin</artifactId>
          <executions>
              <execution>
                  <id>overwrite-sources</id>
                  <phase>generate-sources</phase>
                  <goals>
                      <goal>run</goal>
                  </goals>
                  <configuration>
                      <tasks>
                          <copy todir="${project.build.directory}/generated-sources/jira-reference-plugin" overwrite="true">
                              <fileset dir="src-overrides/main/java" />
                              <fileset dir="src-overrides/main/resources" />
                          </copy>
                      </tasks>
                  </configuration>
              </execution>
          </executions>
      </plugin>


    </plugins>
  </build>
    <dependencies>
        <dependency>
            <groupId>com.atlassian.jira</groupId>
            <artifactId>jira-core</artifactId>
            <scope>provided</scope>
        </dependency>
        <dependency>
            <groupId>com.atlassian.jira</groupId>
            <artifactId>jira-reference-plugin</artifactId>
            <version>${project.version}</version>
            <classifier>sources</classifier>
            <scope>provided</scope>
        </dependency>
        <dependency>
            <groupId>javax.ws.rs</groupId>
            <artifactId>jsr311-api</artifactId>
            <scope>provided</scope>
        </dependency>
        <dependency>
            <groupId>javax.xml.bind</groupId>
            <artifactId>jaxb-api</artifactId>
            <version>2.1</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>javax.servlet-api</artifactId>
            <scope>provided</scope>
        </dependency>
        <dependency>
            <groupId>com.atlassian.templaterenderer</groupId>
            <artifactId>atlassian-template-renderer-api</artifactId>
            <scope>provided</scope>
        </dependency>
        <dependency>
            <groupId>log4j</groupId>
            <artifactId>log4j</artifactId>
            <scope>provided</scope>
        </dependency>
        <dependency>
            <groupId>com.atlassian.activeobjects</groupId>
            <artifactId>activeobjects-plugin</artifactId>
            <version>${activeobjects.version}</version>
            <scope>provided</scope>
        </dependency>
    </dependencies>
  <properties>
    <atlassian.plugin.key>com.atlassian.jira.dev.reference-plugin</atlassian.plugin.key>
    <reference.plugin.version>1.0.1</reference.plugin.version>
  </properties>
</project>
