<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.gadgets</groupId>
        <artifactId>atlassian-gadgets</artifactId>
        <version>3.2.0-m15-BREAKIT</version>
    </parent>
    <artifactId>atlassian-gadgets-publisher-plugin</artifactId>
    <name>Gadget Spec Publisher Plugin</name>
    <description>Plugin which provides a way to publish gadget specs found in plugins</description>
    <packaging>atlassian-plugin</packaging>
    <properties>
        <atlassian.plugin.key>com.atlassian.gadgets.publisher</atlassian.plugin.key>
    </properties>
    <build>
        <plugins>
            <plugin>
                <groupId>com.atlassian.maven.plugins</groupId>
                <artifactId>maven-refapp-plugin</artifactId>
                <configuration>
                    <instructions>
                        <Bundle-SymbolicName>${atlassian.plugin.key}</Bundle-SymbolicName>
                        <Import-Package>
                            javax.xml.bind*;version="${jaxb.version}",*
                        </Import-Package>
                        <Private-Package>
                            com.atlassian.gadgets.publisher.internal.*,
                            com.atlassian.gadgets.util
                        </Private-Package>
                    </instructions>
                </configuration>
            </plugin>
            <plugin>
                <groupId>net.sf.alchim</groupId>
                <artifactId>yuicompressor-maven-plugin</artifactId>
            </plugin>
            <plugin>
                <groupId>org.codehaus.mojo</groupId>
                <artifactId>exec-maven-plugin</artifactId>
                <version>1.1</version>
                <executions>
                    <execution>
                        <goals>
                            <goal>java</goal>
                        </goals>
                        <phase>generate-resources</phase>
                    </execution>
                </executions>
                <configuration>
                    <mainClass>com.google.template.soy.SoyToJsSrcCompiler</mainClass>
                    <includeProjectDependencies>false</includeProjectDependencies>
                    <includePluginDependencies>true</includePluginDependencies>
                    <executableDependency>
                        <groupId>com.google.template.soy</groupId>
                        <artifactId>SoyToJsSrcCompiler</artifactId>
                    </executableDependency>
                    <arguments>
                        <argument>--outputPathFormat</argument>
                        <argument>${project.basedir}/target/classes/templates/messages/{INPUT_FILE_NAME_NO_EXT}.js</argument>
                        <argument>${project.basedir}/src/main/resources/templates/messages/error.soy</argument>
                        <argument>${project.basedir}/src/main/resources/templates/messages/warning.soy</argument>
                        <argument>${project.basedir}/src/main/resources/templates/messages/info.soy</argument>
                    </arguments>
                </configuration>
                <dependencies>
                    <dependency>
                        <groupId>com.google.template.soy</groupId>
                        <artifactId>SoyToJsSrcCompiler</artifactId>
                        <version>20100708</version>
                    </dependency>
                </dependencies>
            </plugin>
        </plugins>
    </build>
    <reporting>
        <plugins>
            <plugin>
                <groupId>gr.abiss.mvn.plugins</groupId>
                <artifactId>maven-jstools-plugin</artifactId>
                <version>0.7-atlassian-1</version>
                <configuration>
                    <jsDir>${basedir}/src/main/resources/ajs-gadgets</jsDir>
                </configuration>
                <reportSets>
                    <reportSet>
                        <reports>
                            <report>jslint</report>
                            <!--<report>jsdoc</report>-->
                        </reports>
                    </reportSet>
                </reportSets>
            </plugin>
        </plugins>
    </reporting>
    <dependencies>
        <!-- Compile-time, bundled dependencies -->
        <dependency>
            <groupId>${pom.groupId}</groupId>
            <artifactId>atlassian-gadgets-shared</artifactId>
            <version>${pom.version}</version>
        </dependency>

        <!-- Provided, non-bundled dependencies -->
        <dependency>
            <groupId>${pom.groupId}</groupId>
            <artifactId>atlassian-gadgets-api</artifactId>
        </dependency>
        <dependency>
            <groupId>${pom.groupId}</groupId>
            <artifactId>atlassian-gadgets-spi</artifactId>
        </dependency>
        <dependency>
            <groupId>com.google.guava</groupId>
            <artifactId>guava</artifactId>
        </dependency>
        <dependency>
            <groupId>com.atlassian.plugins</groupId>
            <artifactId>atlassian-plugins-core</artifactId>
            <scope>provided</scope>
        </dependency>
        <dependency>
            <groupId>org.springframework.osgi</groupId>
            <artifactId>spring-osgi-core</artifactId>
            <version>1.1.3</version>
            <scope>provided</scope>
        </dependency>
        <dependency>
            <groupId>com.atlassian.plugins</groupId>
            <artifactId>atlassian-plugins-webresource</artifactId>
            <scope>provided</scope>
        </dependency>
        <dependency>
            <groupId>com.atlassian.sal</groupId>
            <artifactId>sal-api</artifactId>
            <scope>provided</scope>
        </dependency>
        <dependency>
            <groupId>com.atlassian.cache</groupId>
            <artifactId>atlassian-cache-api</artifactId>
            <version>0.1</version>
            <scope>provided</scope>
        </dependency>
        <dependency>
            <groupId>com.atlassian.plugins.rest</groupId>
            <artifactId>atlassian-rest-common</artifactId>
            <scope>provided</scope>
        </dependency>
        <dependency>
            <groupId>commons-lang</groupId>
            <artifactId>commons-lang</artifactId>
        </dependency>
        <dependency>
            <groupId>commons-logging</groupId>
            <artifactId>commons-logging</artifactId>
            <scope>provided</scope>
        </dependency>
        <dependency>
            <groupId>javax.servlet</groupId>
            <artifactId>servlet-api</artifactId>
        </dependency>
        <dependency>
            <groupId>javax.ws.rs</groupId>
            <artifactId>jsr311-api</artifactId>
        </dependency>
        <dependency>
            <groupId>javax.xml.bind</groupId>
            <artifactId>jaxb-api</artifactId>
        </dependency>
        <dependency>
            <groupId>com.sun.syndication</groupId>
            <artifactId>com.springsource.com.sun.syndication</artifactId>
        </dependency>
        <dependency>
            <groupId>org.slf4j</groupId>
            <artifactId>slf4j-nop</artifactId>
        </dependency>

        <!-- Test-only dependencies -->
        <dependency>
            <groupId>${pom.groupId}</groupId>
            <artifactId>atlassian-gadgets-test-framework</artifactId>
            <version>${pom.version}</version>
            <scope>test</scope>
        </dependency>
    </dependencies>

    <!-- Gadgets does not name its artifacts the way the maven-scm-plugin assumes, so we need to override that here -->
    <scm>
        <connection>scm:svn:https://ecosystem.atlassian.net/svn/AG/trunk/publisher-plugin</connection>
        <developerConnection>scm:svn:https://ecosystem.atlassian.net/svn/AG/trunk/publisher-plugin</developerConnection>
        <url>https://ecosystem.atlassian.net/source/browse/AG/trunk/publisher-plugin</url>
    </scm>
</project>
