<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.robovm</groupId>
        <artifactId>robovm-templates-parent</artifactId>
        <version>1.8.0</version>
    </parent>

    <artifactId>robovm-templater</artifactId>
    <name>RoboVM Template Generator</name>
    <packaging>jar</packaging>

    <properties>
        <robovm.version>1.8.0</robovm.version>
    </properties>

    <dependencies>
        <dependency>
            <groupId>org.apache.commons</groupId>
            <artifactId>commons-compress</artifactId>
            <version>1.5</version>
        </dependency>
        <dependency>
            <groupId>commons-io</groupId>
            <artifactId>commons-io</artifactId>
            <version>2.4</version>
        </dependency>
        <dependency>
            <groupId>junit</groupId>
            <artifactId>junit</artifactId>
            <version>4.12</version>
            <scope>test</scope>
        </dependency>
        <dependency>
            <groupId>org.robovm</groupId>
            <artifactId>robovm-default-template</artifactId>
            <version>${robovm.version}</version>
            <type>tar.gz</type>
        </dependency>
        <dependency>
            <groupId>org.robovm</groupId>
            <artifactId>robovm-single-view-template</artifactId>
            <version>${robovm.version}</version>
            <type>tar.gz</type>
        </dependency>
        <dependency>
            <groupId>org.robovm</groupId>
            <artifactId>robovm-console-template</artifactId>
            <version>${robovm.version}</version>
            <type>tar.gz</type>
        </dependency>
        <dependency>
            <groupId>org.robovm</groupId>
            <artifactId>robovm-cross-platform-template</artifactId>
            <version>${robovm.version}</version>
            <type>tar.gz</type>
        </dependency>
    </dependencies>

    <build>
        <plugins>
            <plugin>
                <artifactId>maven-clean-plugin</artifactId>
                <version>2.5</version>
                <configuration>
                    <filesets>
                        <fileset>
                            <directory>src/main/resources/templates</directory>
                        </fileset>
                    </filesets>
                </configuration>
            </plugin>
            <plugin>
                <groupId>org.apache.maven.plugins</groupId>
                <artifactId>maven-jar-plugin</artifactId>
                <version>2.5</version>
            </plugin>
            <plugin>
                <groupId>org.apache.maven.plugins</groupId>
                <artifactId>maven-dependency-plugin</artifactId>
                <version>2.8</version>
                <configuration>
                    <stripVersion>true</stripVersion>
                    <stripClassifier>true</stripClassifier>
                    <artifactItems>
                        <artifactItem>
                            <groupId>org.robovm</groupId>
                            <artifactId>robovm-default-template</artifactId>
                            <overWrite>true</overWrite>
                            <type>tar.gz</type>
                            <outputDirectory>src/main/resources/templates</outputDirectory>
                        </artifactItem>
                        <artifactItem>
                            <groupId>org.robovm</groupId>
                            <artifactId>robovm-console-template</artifactId>
                            <overWrite>true</overWrite>
                            <type>tar.gz</type>
                            <outputDirectory>src/main/resources/templates</outputDirectory>
                        </artifactItem>
                        <artifactItem>
                            <groupId>org.robovm</groupId>
                            <artifactId>robovm-single-view-template</artifactId>
                            <overWrite>true</overWrite>
                            <type>tar.gz</type>
                            <outputDirectory>src/main/resources/templates</outputDirectory>
                        </artifactItem>
                        <artifactItem>
                            <groupId>org.robovm</groupId>
                            <artifactId>robovm-cross-platform-template</artifactId>
                            <overWrite>true</overWrite>
                            <type>tar.gz</type>
                            <outputDirectory>src/main/resources/templates</outputDirectory>
                        </artifactItem>
                    </artifactItems>
                </configuration>
                <executions>
                    <execution>
                        <id>copy</id>
                        <phase>initialize</phase>
                        <goals>
                            <goal>copy</goal>
                        </goals>
                    </execution>
                </executions>
            </plugin>
            <plugin>
                <groupId>org.codehaus.mojo</groupId>
                <artifactId>build-helper-maven-plugin</artifactId>
                <version>1.1</version>
                <executions>
                    <execution>
                        <id>add-source</id>
                        <phase>generate-sources</phase>
                        <goals>
                            <goal>add-source</goal>
                        </goals>
                        <configuration>
                            <sources>
                                <source>src/main/resources</source>
                            </sources>
                        </configuration>
                    </execution>
                </executions>
            </plugin>
        </plugins>
        <pluginManagement>
            <plugins>
                <plugin>
                    <groupId>org.eclipse.m2e</groupId>
                    <artifactId>lifecycle-mapping</artifactId>
                    <version>1.0.0</version>
                    <configuration>
                        <lifecycleMappingMetadata>
                            <pluginExecutions>
                                <pluginExecution>
                                    <pluginExecutionFilter>
                                        <groupId>org.apache.maven.plugins</groupId>
                                        <artifactId>maven-dependency-plugin</artifactId>
                                        <versionRange>[2.0,)</versionRange>
                                        <goals>
                                            <goal>copy</goal>
                                        </goals>
                                    </pluginExecutionFilter>
                                    <action>
                                        <ignore />
                                    </action>
                                </pluginExecution>
                            </pluginExecutions>
                        </lifecycleMappingMetadata>
                    </configuration>
                </plugin>
            </plugins>
        </pluginManagement>
    </build>

</project>
