<?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>org.sonatype.oss</groupId>
        <artifactId>oss-parent</artifactId>
        <version>7</version>
    </parent>

    <packaging>jar</packaging>
    <groupId>org.webjars</groupId>
    <artifactId>highcharts</artifactId>
    <version>3.0.9</version>
    <name>Highcharts</name>
    <description>WebJar for Highcharts</description>
    <url>http://webjars.org</url>

<!-- NOT SURE IF THIS IS A REQUIRED DEP OR NOT
    <dependencies>
        <dependency>
            <groupId>org.webjars</groupId>
            <artifactId>exportingjs</artifactId>
            <version>3.0.1</version>
        </dependency>
    </dependencies>
-->

    <licenses>
        <license>
            <comments>Non-commercial - Free</comments>
            <name>Creative Commons Attribution-NonCommercial 3.0 License</name>
            <url>http://creativecommons.org/licenses/by-nc/3.0/</url>
            <distribution>repo</distribution>
        </license>
        <license>
            <name>Commercial and government licenses</name>
            <url>http://shop.highsoft.com/highcharts.html/</url>
            <distribution>repo</distribution>
        </license>
    </licenses>

    <scm>
        <url>http://github.com/webjars/highcharts</url>
        <connection>scm:git:https://github.com/webjars/highcharts.git</connection>
        <developerConnection>scm:git:https://github.com/webjars/highcharts.git</developerConnection>
        <tag>highcharts-3.0.9</tag>
    </scm>

    <developers>
        <developer>
            <id>jamesward</id>
            <name>James Ward</name>
            <email>james@jamesward.org</email>
        </developer>
    </developers>

    <properties>
        <project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
        <upstreamVersion>3.0.9</upstreamVersion>
        <downloadUrl>http://code.highcharts.com/${upstreamVersion}</downloadUrl>
        <destinationDir>${project.build.outputDirectory}/META-INF/resources/webjars/${project.artifactId}/${upstreamVersion}</destinationDir>
    </properties>
    
    <build>
        <plugins>
            <plugin>
                <groupId>org.codehaus.mojo</groupId>
                <artifactId>wagon-maven-plugin</artifactId>
                <version>1.0-beta-4</version>
                <executions>
                    <execution>
                        <id>download-highcharts.js</id>
                        <phase>process-resources</phase>
                        <goals><goal>download-single</goal></goals>
                        <configuration>
                            <url>${downloadUrl}</url>
                            <fromFile>highcharts.js</fromFile>
                            <toDir>${destinationDir}</toDir>
                        </configuration>
                    </execution>
                    <execution>
                        <id>download-highcharts-more.js</id>
                        <phase>process-resources</phase>
                        <goals><goal>download-single</goal></goals>
                        <configuration>
                            <url>${downloadUrl}</url>
                            <fromFile>highcharts-more.js</fromFile>
                            <toDir>${destinationDir}</toDir>
                        </configuration>
                    </execution>
                    <execution>
                        <id>download-mootools-adapter.js</id>
                        <phase>process-resources</phase>
                        <goals><goal>download-single</goal></goals>
                        <configuration>
                            <url>${downloadUrl}/adapters</url>
                            <fromFile>mootools-adapter.js</fromFile>
                            <toDir>${destinationDir}/adapters</toDir>
                        </configuration>
                    </execution>
                    <execution>
                        <id>download-prototype-adapter.js</id>
                        <phase>process-resources</phase>
                        <goals><goal>download-single</goal></goals>
                        <configuration>
                            <url>${downloadUrl}/adapters</url>
                            <fromFile>prototype-adapter.js</fromFile>
                            <toDir>${destinationDir}/adapters</toDir>
                        </configuration>
                    </execution>
                </executions>
            </plugin>
            <plugin>
                <groupId>org.apache.maven.plugins</groupId>
                <artifactId>maven-release-plugin</artifactId>
                <version>2.4.2</version>
                <dependencies>
                    <dependency>
                        <groupId>org.apache.maven.scm</groupId>
                        <artifactId>maven-scm-provider-gitexe</artifactId>
                        <version>1.9</version>
                    </dependency>
                </dependencies>
            </plugin>

            <plugin>
                <groupId>org.sonatype.plugins</groupId>
                <artifactId>nexus-staging-maven-plugin</artifactId>
                <version>1.5.1</version>
                <extensions>true</extensions>
                <configuration>
                    <serverId>sonatype-nexus-staging</serverId>
                    <nexusUrl>https://oss.sonatype.org/</nexusUrl>
                    <autoReleaseAfterClose>true</autoReleaseAfterClose>
                </configuration>
            </plugin>
        </plugins>
    </build>

</project>
