<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>
  <groupId>org.fanout</groupId>
  <artifactId>fanout</artifactId>
  <packaging>jar</packaging>
  <version>1.0.0</version>
  <name>fanout</name>
  <description>Java library for Fanout.io.</description>
  <url>https://github.com/fanout/java-fanout</url>
  <scm>
    <connection>scm:git:git@github.com:fanout/java-fanout.git</connection>
    <developerConnection>scm:git:git@github.com:fanout/java-fanout.git</developerConnection>
    <url>git@github.com:fanout/java-fanout.git</url>
  </scm>
  <developers>
    <developer>
      <name>Konstantin Bokarius</name>
      <email>kon@fanout.io</email>
      <organization>Fanout</organization>
      <organizationUrl>http://www.fanout.io</organizationUrl>
    </developer>
  </developers>
  <licenses>
	<license>
      <name>MIT License</name>
	  <url>http://www.opensource.org/licenses/mit-license.php</url>
      <distribution>repo</distribution>
	</license>
  </licenses>
  <dependencies>
    <dependency>
      <groupId>junit</groupId>
      <artifactId>junit</artifactId>
      <version>4.12</version>
      <scope>test</scope>
    </dependency>
    <dependency>
      <groupId>org.fanout</groupId>
      <artifactId>pubcontrol</artifactId>
      <version>1.0.7</version>
    </dependency>
  </dependencies>
  <distributionManagement>
	<snapshotRepository>
		<id>sonatype-nexus-snapshots</id>
		<name>Sonatype Nexus snapshot repository</name>
		<url>https://oss.sonatype.org/content/repositories/snapshots</url>
	</snapshotRepository>
	<repository>
		<id>sonatype-nexus-staging</id>
		<name>Sonatype Nexus release repository</name>
		<url>https://oss.sonatype.org/service/local/staging/deploy/maven2/</url>
	</repository>
  </distributionManagement>
  <build>
    <plugins>
      <plugin>
	    <groupId>org.apache.maven.plugins</groupId>
	    <artifactId>maven-release-plugin</artifactId>
	    <version>2.2.2</version>
	    <configuration>
		  <arguments>-Dgpg.passphrase=${gpg.passphrase}</arguments>
    	</configuration>
      </plugin>
      <plugin>
        <groupId>org.apache.maven.plugins</groupId>
        <artifactId>maven-enforcer-plugin</artifactId>
        <version>1.4.1</version>
        <executions>
          <execution>
            <id>enforce-java</id>
            <goals>
              <goal>enforce</goal>
            </goals>
            <configuration>
              <rules>
                <requireJavaVersion>
                  <version>1.6.0</version>
                </requireJavaVersion>
              </rules>
            </configuration>
          </execution>
        </executions>
      </plugin>
    </plugins>
  </build>
  <profiles>
	<profile>
	  <id>release-sign-artifacts</id>
	  <activation>
	    <property>
	      <name>performRelease</name>
		  <value>true</value>
		</property>
	  </activation>
	  <build>
	    <plugins>
          <plugin>
            <groupId>org.apache.maven.plugins</groupId>
            <artifactId>maven-source-plugin</artifactId>
            <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>
            <executions>
              <execution>
                <id>attach-javadocs</id>
                <goals>
                  <goal>jar</goal>
                </goals>
              </execution>
            </executions>
          </plugin>
	      <plugin>
	        <groupId>org.apache.maven.plugins</groupId>
			<artifactId>maven-gpg-plugin</artifactId>
			<version>1.4</version>
			<configuration>
			  <passphrase>${gpg.passphrase}</passphrase>
			</configuration>
			<executions>
		      <execution>
			    <id>sign-artifacts</id>
			    <phase>verify</phase>
			    <goals>
			      <goal>sign</goal>
				</goals>
			  </execution>
			</executions>
	      </plugin>
		</plugins>
      </build>
    </profile>
  </profiles>
</project>
