<?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>9</version>
  </parent>

  <groupId>de.javagl</groupId>
  <artifactId>jgltf-parent</artifactId>
  <packaging>pom</packaging>
  <version>2.0.0</version>

  <scm>
    <connection>scm:git:git@github.com:javagl/JglTF.git</connection>
    <developerConnection>scm:git:git@github.com:javagl/JglTF.git</developerConnection>
    <url>git@github.com:javagl/JglTF.git</url>
  </scm>

  <developers>
    <developer>
      <name>Marco Hutter</name>
      <email>javagl@javagl.de</email>
    </developer>
  </developers>

  <licenses>
    <license>
      <name>MIT X11 License</name>
      <url>https://github.com/javagl/JglTF/blob/master/LICENSE</url>
      <distribution>repo</distribution>
    </license>
  </licenses>

  <properties>
    <project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
  </properties>

  <modules>
    <module>jgltf-impl-v1</module>
    <module>jgltf-impl-v2</module>
    <module>jgltf-impl-v2-technique-webgl</module>
    <module>jgltf-model</module>
    <module>jgltf-obj</module>
    <module>jgltf-validator</module>
    <module>jgltf-viewer</module>
    <module>jgltf-viewer-jogl</module>
    <module>jgltf-viewer-lwjgl</module>
  </modules>

  <build>

    <plugins>

      <!-- Copy all JARs of the submodules and dependencies into the target
      <plugin>
        <groupId>org.apache.maven.plugins</groupId>
        <artifactId>maven-dependency-plugin</artifactId>
        <version>2.10</version>
        <executions>

          <execution>
            <id>copy-artifact</id>
            <phase>package</phase>
            <goals>
              <goal>copy</goal>
            </goals>
            <configuration>
              <artifactItems>
                <artifactItem>
                  <groupId>${project.groupId}</groupId>
                  <artifactId>${project.artifactId}</artifactId>
                  <version>${project.version}</version>
                  <type>${project.packaging}</type>
                </artifactItem>
              </artifactItems>
              <outputDirectory>../target</outputDirectory>
            </configuration>
          </execution>

          <execution>
            <id>copy-artifact-sources</id>
            <phase>package</phase>
            <goals>
              <goal>copy</goal>
            </goals>
            <configuration>
              <artifactItems>
                <artifactItem>
                  <groupId>${project.groupId}</groupId>
                  <artifactId>${project.artifactId}</artifactId>
                  <version>${project.version}</version>
                  <classifier>sources</classifier>
                  <type>${project.packaging}</type>
                </artifactItem>
              </artifactItems>
              <outputDirectory>../target/sources</outputDirectory>
            </configuration>
          </execution>

          <execution>
            <id>copy-artifact-javadoc</id>
            <phase>package</phase>
            <goals>
              <goal>copy</goal>
            </goals>
            <configuration>
              <artifactItems>
                <artifactItem>
                  <groupId>${project.groupId}</groupId>
                  <artifactId>${project.artifactId}</artifactId>
                  <version>${project.version}</version>
                  <classifier>javadoc</classifier>
                  <type>${project.packaging}</type>
                </artifactItem>
              </artifactItems>
              <outputDirectory>../target/javadoc</outputDirectory>
            </configuration>
          </execution>

          <execution>
            <phase>package</phase>
            <goals>
              <goal>copy-dependencies</goal>
            </goals>
            <configuration>
              <outputDirectory>../target</outputDirectory>
            </configuration>
          </execution>

          <execution>
            <id>copy-dependencies-sources</id>
            <phase>package</phase>
            <goals>
              <goal>copy-dependencies</goal>
            </goals>
            <configuration>
              <classifier>sources</classifier>
              <outputDirectory>../target/sources</outputDirectory>
            </configuration>
          </execution>

          <execution>
            <id>copy-dependencies-javadoc</id>
            <phase>package</phase>
            <goals>
              <goal>copy-dependencies</goal>
            </goals>
            <configuration>
              <classifier>javadoc</classifier>
              <outputDirectory>../target/javadoc</outputDirectory>
            </configuration>
          </execution>

        </executions>
      </plugin>
      -->
    </plugins>

    <pluginManagement>
      <plugins>

        <plugin>
          <groupId>org.apache.maven.plugins</groupId>
          <artifactId>maven-compiler-plugin</artifactId>
          <version>3.1</version>
          <configuration>
            <source>1.8</source>
            <target>1.8</target>
          </configuration>
        </plugin>

        <plugin>
          <groupId>org.apache.maven.plugins</groupId>
          <artifactId>maven-source-plugin</artifactId>
          <version>2.1.2</version>
          <executions>
            <execution>
              <id>attach-sources</id>
              <goals>
                <goal>jar</goal>
              </goals>
            </execution>
          </executions>
        </plugin>

        <plugin>
          <groupId>org.apache.maven.plugins</groupId>
          <artifactId>maven-javadoc-plugin</artifactId>
          <version>2.10.1</version>

          <executions>
            <execution>
              <id>attach-javadocs</id>
              <goals>
                <goal>jar</goal>
              </goals>
            </execution>
          </executions>
        </plugin>

      </plugins>
    </pluginManagement>
  </build>

</project>