<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>de.erichseifert.vectorgraphics2d</groupId>
  <artifactId>VectorGraphics2D</artifactId>
  <name>VectorGraphics2D Library</name>
  <version>0.9.3</version>
  <url>https://github.com/eseifert/vectorgraphics2d</url>
  <description>A library for adding vector export to Java(R) Graphics2D.</description>
  <inceptionYear>2010</inceptionYear>

  <licenses>
    <license>
        <name>GNU Library or Lesser General Public License (LGPL)</name>
        <url>http://www.gnu.org/licenses/lgpl.txt</url>
    </license>
  </licenses>

  <developers>
    <developer>
    	<id>eseifert</id>
        <name>Erich Seifert</name>
        <email>dev[at]erichseifert.de</email>
        <timezone>+1</timezone>
    </developer>
  </developers>

  <properties>
    <project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
    <compileSource>1.5</compileSource>
    <runtime.jar>${java.home}/lib/rt.jar</runtime.jar>
  </properties>

  <profiles>
    <profile>
      <id>macosx</id>
      <properties>
        <runtime.jar>${java.home}/bundle/Classes/classes.jar</runtime.jar>
      </properties>
    </profile>
    <profile>
      <id>proguard</id>
      <build>
        <plugins>
          <plugin>
            <groupId>com.github.wvengen</groupId>
            <artifactId>proguard-maven-plugin</artifactId>
            <version>2.0.6</version>
            <executions>
              <execution>
                <phase>package</phase>
                <goals><goal>proguard</goal></goals>
              </execution>
            </executions>
            <configuration>
              <proguardInclude>src/etc/proguard.conf</proguardInclude>
                <options>
                  <option>-target ${compileSource}</option>
                </options>
                <libs>
                  <lib>${runtime.jar}</lib>
                </libs>
              <proguardVersion>4.9</proguardVersion>
            </configuration>
            <dependencies>
              <dependency>
                <groupId>net.sf.proguard</groupId>
                <artifactId>proguard-base</artifactId>
                <version>4.9</version>
                <scope>runtime</scope>
              </dependency>
            </dependencies>
          </plugin>
        </plugins>
      </build>
    </profile>
    <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-gpg-plugin</artifactId>
            <version>1.6</version>
            <executions>
              <execution>
                <id>sign-artifacts</id>
                <phase>verify</phase>
                <goals>
                  <goal>sign</goal>
                </goals>
              </execution>
            </executions>
          </plugin>
        </plugins>
      </build>
    </profile>
  </profiles>

  <build>
  	<plugins>
  		<plugin>
  			<artifactId>maven-compiler-plugin</artifactId>
  			<version>2.3.2</version>
  			<configuration>
                <source>${compileSource}</source>
                <target>${compileSource}</target>
  			</configuration>
  		</plugin>
  		<plugin>
  			<groupId>com.mycila.maven-license-plugin</groupId>
  			<artifactId>maven-license-plugin</artifactId>
            <version>1.9.0</version>
  			<configuration>
                <header>src/etc/header.txt</header>
                <mapping>
                    <java>SLASHSTAR_STYLE</java>
                </mapping>
                <properties>
                    <owner>Erich Seifert</owner>
                    <year>${project.inceptionYear}-2015</year>
                    <email>dev[at]erichseifert.de</email>
                </properties>
                <excludes>
                    <exclude>LICENSE.GPL</exclude>
                    <exclude>LICENSE.LGPL</exclude>
                    <exclude>.*/**</exclude>
                    <exclude>bin/**</exclude>
                    <exclude>src/main/resources/**</exclude>
                    <exclude>src/test/resources/**</exclude>
                </excludes>
  			</configuration>
  			<executions>
                <execution>
                    <phase>test</phase>
                    <goals>
                        <goal>check</goal>
                    </goals>
                </execution>
            </executions>
  		</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.8</version>
        <configuration>
          <show>protected</show>
          <nohelp>true</nohelp>
        </configuration>
        <executions>
          <execution>
            <id>attach-javadocs</id>
            <goals>
              <goal>jar</goal>
            </goals>
          </execution>
        </executions>
      </plugin>
        <plugin>
            <artifactId>maven-site-plugin</artifactId>
            <version>3.0</version>
        </plugin>
        <plugin>
            <artifactId>maven-assembly-plugin</artifactId>
            <version>2.2.1</version>
            <configuration>
                <descriptorRefs>
                    <descriptorRef>bin</descriptorRef>
                    <descriptorRef>src</descriptorRef>
                </descriptorRefs>
            </configuration>
            <executions>
                <execution>
                    <id>Assemble jar with dependencies</id>
                    <phase>package</phase>
                    <goals>
                        <goal>single</goal>
                    </goals>
                </execution>
            </executions>
        </plugin>
        <plugin>
          <groupId>org.apache.maven.plugins</groupId>
          <artifactId>maven-release-plugin</artifactId>
          <version>2.5.2</version>
          <configuration>
            <pushChanges>false</pushChanges>
          </configuration>
        </plugin>
    </plugins>
  </build>

  <reporting>
    <plugins>
        <plugin>
            <groupId>org.apache.maven.plugins</groupId>
            <artifactId>maven-jxr-plugin</artifactId>
            <version>2.3</version>
            <configuration>
                <inputEncoding>UTF-8</inputEncoding>
                <outputEncoding>UTF-8</outputEncoding>
            </configuration>
        </plugin>
        <plugin>
            <groupId>org.apache.maven.plugins</groupId>
            <artifactId>maven-changelog-plugin</artifactId>
            <version>2.2</version>
        </plugin>
        <plugin>
            <groupId>org.apache.maven.plugins</groupId>
        	<artifactId>maven-surefire-report-plugin</artifactId>
            <version>2.10</version>
      	</plugin>
        <plugin>
        	<groupId>org.apache.maven.plugins</groupId>
        	<artifactId>maven-javadoc-plugin</artifactId>
            <version>2.8</version>
        	<configuration>
          		<show>public</show>
        	</configuration>
        </plugin>
        <plugin>
            <groupId>org.apache.maven.plugins</groupId>
            <artifactId>maven-pmd-plugin</artifactId>
            <version>2.5</version>
            <configuration>
                <linkXRef>true</linkXRef>
                <targetJdk>${compileSource}</targetJdk>
            </configuration>
        </plugin>
    </plugins>
  </reporting>

  <dependencies>
  	<dependency>
  		<groupId>junit</groupId>
  		<artifactId>junit</artifactId>
  		<version>4.10</version>
  		<scope>test</scope>
  		<optional>true</optional>
  	</dependency>
  </dependencies>

  <scm>
    <url>git@github.com:eseifert/vectorgraphics2d.git</url>
    <connection>scm:git:ssh://erichseifert.de/vectorgraphics2d.git</connection>
    <developerConnection>scm:git:ssh://git@erichseifert.de/vectorgraphics2d.git</developerConnection>
    <tag>VectorGraphics2D-0.9.3</tag>
  </scm>

  <issueManagement>
    <system>trac</system>
    <url>http://trac.erichseifert.de/vectorgraphics2d/</url>
  </issueManagement>

  <distributionManagement>
    <snapshotRepository>
      <id>sonatype-nexus-snapshots</id>
      <name>Sonatype Nexus Snapshots</name>
      <url>http://oss.sonatype.org/content/repositories/snapshots</url>
    </snapshotRepository>
    <repository>
      <id>sonatype-nexus-staging</id>
      <name>Nexus Release Repository</name>
      <url>http://oss.sonatype.org/service/local/staging/deploy/maven2/</url>
    </repository>
    <downloadUrl>https://oss.sonatype.org/content/groups/public/de/erichseifert/vectorgraphics2d</downloadUrl>
  </distributionManagement>
</project>
