<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/xsd/maven-4.0.0.xsd">
  <modelVersion>4.0.0</modelVersion>

  <groupId>io.takari.m2e.workspace</groupId>
  <artifactId>org.eclipse.m2e.workspace.cli</artifactId>
  <version>0.3.0</version>

  <name>m2e-workspace</name>
  <description>
  Workspace dependency resolver implementation for Maven command line build.
  </description>
  <url>https://www.eclipse.org/m2e</url>

  <organization>
    <name>eclipse m2e</name>
    <url>https://www.eclipse.org/m2e</url>
  </organization>

  <licenses>
    <license>
      <name>Eclipse Public License - v 1.0</name>
      <url>http://www.eclipse.org/legal/epl-v10.html</url>
    </license>
  </licenses>

  <issueManagement>
    <system>Bugzilla</system>
    <url>https://bugs.eclipse.org/bugs/enter_bug.cgi?product=m2e</url>
  </issueManagement>

  <scm>
    <url>http://git.eclipse.org/c/m2e/org.eclipse.m2e.workspace.git/</url>
    <connection>scm:git:git://git.eclipse.org/gitroot/m2e/org.eclipse.m2e.workspace.git</connection>
    <developerConnection>scm:git:ssh://git.eclipse.org/gitroot/m2e/org.eclipse.m2e.workspace.git</developerConnection>
    <tag>m2e-workspace-0.3.0</tag>
  </scm>

  <developers>
    <developer>
      <id>ifedorenk</id>
      <name>Igor Fedorenko</name>
      <organization>Takari Inc.</organization>
      <timezone>-5</timezone>
    </developer>
  </developers>

  <distributionManagement>
    <repository>
      <id>${releaseRepoId}</id>
      <url>${releaseRepoUrl}</url>
    </repository>
    <snapshotRepository>
      <id>${snapshotRepoId}</id>
      <url>${snapshotRepoUrl}</url>
    </snapshotRepository>
  </distributionManagement>

  <properties>
    <project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
    <maven-core.version>2.0</maven-core.version>
  </properties>

  <dependencies>
    <dependency>
      <groupId>org.apache.maven</groupId>
      <artifactId>maven-core</artifactId>
      <version>${maven-core.version}</version>
      <scope>provided</scope>
    </dependency>

    <dependency>
      <groupId>javax.inject</groupId>
      <artifactId>javax.inject</artifactId>
      <version>1</version>
    </dependency>
    <dependency>
      <groupId>org.codehaus.plexus</groupId>
      <artifactId>plexus-component-annotations</artifactId>
      <version>1.5.5</version>
    </dependency>

    <dependency>
      <!-- aether version included in maven 3.0 -->
      <groupId>org.sonatype.aether</groupId>
      <artifactId>aether-api</artifactId>
      <version>1.7</version>
      <scope>provided</scope>
    </dependency>

    <dependency>
      <!-- aether version included in maven [3.1.1,3.2.3] was 0.9.0.M2 -->
      <!-- aether version included in maven [3.2.4,) is 1.0.0.v20140518 -->
      <!-- both appear to work without changes to workspace resolver code -->
      <groupId>org.eclipse.aether</groupId>
      <artifactId>aether-api</artifactId>
      <version>1.0.0.v20140518</version>
      <scope>provided</scope>
    </dependency>

  </dependencies>

  <build>
    <plugins>
      <plugin>
        <groupId>org.sonatype.plugins</groupId>
        <artifactId>sisu-maven-plugin</artifactId>
      </plugin>
      <plugin>
        <groupId>org.codehaus.plexus</groupId>
        <artifactId>plexus-component-metadata</artifactId>
        <version>1.0.0</version>
        <executions>
          <execution>
            <goals>
              <goal>generate-metadata</goal>
              <goal>generate-test-metadata</goal>
            </goals>
          </execution>
        </executions>
      </plugin>
      <plugin>
        <groupId>org.apache.felix</groupId>
        <artifactId>maven-bundle-plugin</artifactId>
        <configuration>
          <instructions>
            <Bundle-SymbolicName>org.eclipse.m2e.workspace.cli;singleton:=false</Bundle-SymbolicName>
            <Export-Package>org.eclipse.m2e.workspace</Export-Package>
          </instructions>
        </configuration>
      </plugin>
      <plugin>
        <groupId>org.apache.maven.plugins</groupId>
        <artifactId>maven-source-plugin</artifactId>
      </plugin>
      <plugin>
        <groupId>org.apache.maven.plugins</groupId>
        <artifactId>maven-jar-plugin</artifactId>
        <configuration>
          <archive>
            <manifestFile>${project.build.outputDirectory}/META-INF/MANIFEST.MF</manifestFile>
          </archive>
        </configuration>
      </plugin>
    </plugins>

    <pluginManagement>
      <plugins>
        <plugin>
          <groupId>org.apache.maven.plugins</groupId>
          <artifactId>maven-compiler-plugin</artifactId>
          <version>3.1</version>
          <configuration>
            <!-- http://maven.apache.org/plugins/maven-compiler-plugin/ -->
            <source>1.7</source>
            <target>1.7</target>
          </configuration>
        </plugin>
        <plugin>
          <groupId>org.sonatype.plugins</groupId>
          <artifactId>sisu-maven-plugin</artifactId>
          <version>1.1</version>
          <executions>
            <execution>
              <id>generate-index</id>
              <goals>
                <goal>main-index</goal>
              </goals>
            </execution>
          </executions>
        </plugin>
        <plugin>
          <groupId>org.apache.felix</groupId>
          <artifactId>maven-bundle-plugin</artifactId>
          <version>2.5.0</version>
          <executions>
            <execution>
              <id>bundle-manifest</id>
              <phase>process-classes</phase>
              <goals>
                <goal>manifest</goal>
              </goals>
              <configuration>
                <instructions>
                  <_failok>true</_failok>
                  <_nouses>true</_nouses>
                  <_nodefaultversion>true</_nodefaultversion>
                  <_snapshot>${osgi-version-qualifier}</_snapshot>

                  <Bundle-RequiredExecutionEnvironment>JavaSE-1.7,JavaSE-1.8</Bundle-RequiredExecutionEnvironment>

                  <Import-Package>!*</Import-Package>
                </instructions>
              </configuration>
            </execution>
          </executions>
        </plugin>
        <plugin>
          <groupId>org.apache.maven.plugins</groupId>
          <artifactId>maven-source-plugin</artifactId>
          <version>2.2.1</version>
          <executions>
            <execution>
              <id>attach-sources</id>
              <goals>
                <goal>jar-no-fork</goal>
              </goals>
            </execution>
          </executions>
        </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-surefire-plugin</artifactId>
          <version>2.17</version>
        </plugin>
        <plugin>
          <inherited>true</inherited>
          <groupId>org.apache.maven.plugins</groupId>
          <artifactId>maven-deploy-plugin</artifactId>
          <version>2.8.1</version>
        </plugin>
        <plugin>
          <groupId>org.apache.maven.plugins</groupId>
          <artifactId>maven-gpg-plugin</artifactId>
          <version>1.5</version>
        </plugin>
        <plugin>
          <inherited>true</inherited>
          <groupId>org.apache.maven.plugins</groupId>
          <artifactId>maven-release-plugin</artifactId>
          <version>2.5.1</version>
          <configuration>
            <localCheckout>true</localCheckout>
            <pushChanges>false</pushChanges>
            <tagNameFormat>m2e-workspace-@{project.version}</tagNameFormat>
            <arguments>-Ptakari-release</arguments>
          </configuration>
        </plugin>
      </plugins>
    </pluginManagement>

  </build>

  <profiles>
    <profile>
      <id>m2e</id>
      <activation>
        <property>
          <name>m2e.version</name>
        </property>
      </activation>
      <properties>
        <osgi-version-qualifier>qualifier</osgi-version-qualifier>
      </properties>
      <build>
        <pluginManagement>
          <plugins>
            <plugin>
              <groupId>org.apache.felix</groupId>
              <artifactId>maven-bundle-plugin</artifactId>
              <configuration>
                <!-- PDE does not honour custom manifest location -->
                <manifestLocation>META-INF</manifestLocation>
              </configuration>
            </plugin>
          </plugins>
        </pluginManagement>
      </build>
    </profile>

    <profile>
      <id>takari-release</id>
      <build>
        <plugins>
          <plugin>
            <groupId>org.apache.maven.plugins</groupId>
            <artifactId>maven-gpg-plugin</artifactId>
            <configuration>
              <passphrase>${gpg.passphrase}</passphrase>
            </configuration>
            <executions>
              <execution>
                <goals>
                  <goal>sign</goal>
                </goals>
              </execution>
            </executions>
          </plugin>
          <plugin>
            <groupId>org.apache.maven.plugins</groupId>
            <artifactId>maven-surefire-plugin</artifactId>
            <configuration>
              <skip>true</skip>
            </configuration>
          </plugin>
        </plugins>
      </build>
    </profile>
  </profiles>

</project>
