<?xml version="1.0" encoding="UTF-8"?>
<project
        xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd"
        xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">

  <modelVersion>4.0.0</modelVersion>

  <groupId>org.fusesource.ide</groupId>
  <artifactId>rcp-build</artifactId>
  <version>7.2.129</version>
  <packaging>pom</packaging>
  <name>Fuse IDE :: RCP</name>

  <properties>
    <tycho-version>0.16.0</tycho-version>
    <fuse.version>6.0.0</fuse.version>
    <ide-buildno>129</ide-buildno>
  </properties>
  
  <distributionManagement>
    <repository>
      <id>release.fusesource.org</id>
      <name>Fusesource Release Repository</name>
      <!-- <url>http://repo.fusesource.com/nexus/service/local/staging/deploy/maven2</url>
         <url>dav:http://fusesource.com/forge/dav/rider/update/${project.version}</url> -->
      <url>scpexe://repo.fusesource.com/www/repo.fusesource.com/beta/updatesite/${project.version}</url>
    </repository>
    <snapshotRepository>
      <id>snapshot.fusesource.org</id>
      <name>Fusesource Nexus Snapshots</name>
      <!-- <url>http://repo.fusesource.com/nexus/content/repositories/subscriber-snapshot</url>
         <url>dav:http://fusesource.com/forge/dav/rider/update-snapshot/${project.version}</url> -->
      <url>scpexe://repo.fusesource.com/www/repo.fusesource.com/beta/experimental/snapshot</url>
    </snapshotRepository>
    <site>
      <id>website.fusesource.org</id>
      <name>website</name>
      <url>dav:http://fusesource.com/forge/dav/rider/maven/${project.version}</url>
    </site>
  </distributionManagement>

  <build>
    <plugins>
      <plugin>
        <groupId>org.eclipse.tycho</groupId>
        <artifactId>tycho-maven-plugin</artifactId>
        <version>${tycho-version}</version>
        <extensions>true</extensions>
      </plugin>
      <plugin>
        <groupId>org.eclipse.tycho</groupId>
        <artifactId>tycho-compiler-plugin</artifactId>
        <version>${tycho-version}</version>
        <configuration>
          <source>1.6</source>
          <target>1.6</target>
        </configuration>
      </plugin>
      <plugin>
        <groupId>org.eclipse.tycho</groupId>
        <artifactId>target-platform-configuration</artifactId>
        <version>${tycho-version}</version>
        <configuration>
          <resolver>p2</resolver>
          <pomDependencies>consider</pomDependencies>
          <target>
            <artifact>
              <groupId>org.fusesource.ide</groupId>
              <artifactId>org.fusesource.ide.rcp.targetplatform</artifactId>
              <version>7.2.129</version>
              <classifier>indigo</classifier>
            </artifact>
          </target>
          <ignoreTychoRepositories>false</ignoreTychoRepositories>
          <environments> 
             <environment>
                <os>win32</os>
                <ws>win32</ws>
                <arch>x86</arch>
             </environment>
             <environment>
                <os>win32</os>
                <ws>win32</ws>
                <arch>x86_64</arch>
             </environment>
             <environment>
                <os>linux</os>
                <ws>gtk</ws>
                <arch>x86_64</arch>
             </environment>
             <environment>
                <os>linux</os>
                <ws>gtk</ws>
                <arch>x86</arch>
             </environment>
             <environment>
                <os>macosx</os>
                <ws>cocoa</ws>
                <arch>x86_64</arch>
             </environment>
          </environments>
        </configuration>
      </plugin>
      <!-- necessary to omit the maven pom.xml inside the generated jar files -->
      <plugin>
          <groupId>org.eclipse.tycho</groupId>
          <artifactId>tycho-packaging-plugin</artifactId>
          <version>${tycho-version}</version>
          <configuration>
              <!--  <includeSources>true</includeSources> -->
              <archive>
                  <addMavenDescriptor>false</addMavenDescriptor>
              </archive>
          </configuration>
      </plugin>
    </plugins>
  </build>
  
  <pluginRepositories>
    <pluginRepository>
      <id>m2eclipse-snapshot</id>
      <url>https://repository.sonatype.org/content/repositories/snapshots</url>
      <snapshots>
        <enabled>true</enabled>
        <updatePolicy>daily</updatePolicy>
      </snapshots>
      <releases>
        <enabled>false</enabled>
      </releases>
    </pluginRepository>
  </pluginRepositories>

  <profiles>
    <profile>
      <id>sign</id>
      <!-- To sign plug-ins and features, run: mvn -Psign -Dkeystore=<path>
         -Dstorepass=*** -Dalias=<keyalias> clean install -->
      <build>
        <pluginManagement>
          <plugins>
            <plugin>
              <groupId>org.apache.maven.plugins</groupId>
              <artifactId>maven-jar-plugin</artifactId>
              <version>2.3.1</version>
              <executions>
                <execution>
                  <goals>
                    <goal>sign</goal>
                  </goals>
                </execution>
              </executions>
              <configuration>
                <verify>true</verify>
                <jarPath>${project.build.directory}/${project.build.finalName}.jar</jarPath>
              </configuration>
            </plugin>
          </plugins>
        </pluginManagement>
      </build>
    </profile>
  </profiles>
  
  <repositories>
  	<repository>
        <id>ide-beta</id>
        <name>Fuse IDE Beta Update Site</name>
        <url>http://repo.fusesource.com/beta/updatesite/</url>
        <layout>p2</layout>
    </repository>
  </repositories>

  <modules>
    <module>org.fusesource.ide.rcp.branding</module>
    <module>org.fusesource.ide.rcp.feature</module>
    <module>org.fusesource.ide.rcp.targetplatform</module>
    <module>org.fusesource.ide.rcp.product</module>
  </modules>

</project>
