<?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>
  <groupId>org.spockframework</groupId>
  <artifactId>spock-parent</artifactId>
  <packaging>pom</packaging>
  <version>0.5-groovy-1.8</version>
  <name>Spock Framework - Umbrella Project</name>
  <url>http://spockframework.org</url>
  <description>Spock is a testing and specification framework for Java and Groovy applications.</description>

  <licenses>
    <license>
      <name>The Apache Software License, Version 2.0</name>
      <url>http://www.apache.org/licenses/LICENSE-2.0.txt</url>
      <distribution>repo</distribution>
    </license>
  </licenses>

  <scm>
    <connection>scm:svn:http://spock.googlecode.com/svn</connection>
    <developerConnection>scm:svn:https://spock.googlecode.com/svn</developerConnection>
    <url>http://code.google.com/p/spock/source/browse</url>
  </scm>

  <properties>
    <project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
    <project.reporting.outputEncoding>UTF-8</project.reporting.outputEncoding>
  </properties>

  <build>
    <pluginManagement>
      <plugins>
        <plugin>
          <artifactId>maven-compiler-plugin</artifactId>
          <version>2.3.2</version>
          <configuration>
            <source>1.5</source>
            <target>1.5</target>
          </configuration>
        </plugin>
        <plugin>
          <artifactId>maven-surefire-plugin</artifactId>
          <version>2.6</version>
          <configuration>
            <useFile>false</useFile>
          </configuration>
        </plugin>
        <plugin>
          <artifactId>maven-deploy-plugin</artifactId>
          <version>2.5</version> 
        </plugin>
        <plugin>
          <artifactId>maven-release-plugin</artifactId>
          <version>2.1</version>
        </plugin>
        <plugin>
          <groupId>org.codehaus.gmaven</groupId>
          <artifactId>gmaven-plugin</artifactId>
          <version>1.3</version>
          <configuration>
            <providerSelection>1.7</providerSelection>
          </configuration>
          <executions>
            <execution>
              <id>compile-groovy</id>
              <goals>
                <goal>compile</goal>
                <goal>testCompile</goal>
              </goals>
            </execution>
            <execution>
              <id>init-groovy</id>
              <phase>initialize</phase>
              <goals>
                <goal>execute</goal>
              </goals>
              <configuration>
                <source>
                  // the purpose of this script is to make sure that
                  // maven-source-plugin includes Groovy sources in source Jar
                  project.addCompileSourceRoot("$project.basedir/src/main/groovy")
                </source>
              </configuration>
            </execution>
          </executions>
          <dependencies>
            <dependency>
              <groupId>org.codehaus.gmaven.runtime</groupId>
              <artifactId>gmaven-runtime-1.7</artifactId>
              <version>1.3</version>
              <exclusions>
                <exclusion>
                  <groupId>org.codehaus.groovy</groupId>
                  <artifactId>groovy-all</artifactId>
                </exclusion>
              </exclusions>
            </dependency>
            <dependency>
              <groupId>org.codehaus.groovy</groupId>
              <artifactId>groovy-all</artifactId>
              <version>1.8.0-beta-3-SNAPSHOT</version>
            </dependency> 
            <dependency> <!-- required by GMaven's execute goal -->
               <groupId>org.apache.ant</groupId>
               <artifactId>ant</artifactId>    
               <version>1.7.1</version>
             </dependency>
             <dependency> <!-- required by GMaven's execute goal -->
               <groupId>org.apache.ant</groupId>
               <artifactId>ant-launcher</artifactId>     
               <version>1.7.1</version>
             </dependency>
          </dependencies>
        </plugin>
        <plugin>
          <groupId>org.spockframework</groupId>
          <artifactId>spock-maven</artifactId>
          <version>${project.version}</version>
          <executions>
            <execution>
              <goals>
                <goal>find-specs</goal>
              </goals>
            </execution>
          </executions>
        </plugin>
      </plugins>
    </pluginManagement>
  </build>

  <dependencyManagement>
    <dependencies>
      <dependency>
        <groupId>org.codehaus.groovy</groupId>
        <artifactId>groovy-all</artifactId>
        <version>1.8.0-beta-3-SNAPSHOT</version>
      </dependency>
      <dependency>
        <groupId>junit</groupId>
        <artifactId>junit-dep</artifactId>
        <version>4.8.2</version>
      </dependency>
      <dependency>
        <groupId>org.hamcrest</groupId>
        <artifactId>hamcrest-core</artifactId>
        <version>1.2</version>
      </dependency>
      <dependency>
        <groupId>asm</groupId>
        <artifactId>asm</artifactId>
        <version>3.2</version> <!-- use same version as Groovy 1.8 -->
      </dependency>
      <dependency>
        <groupId>cglib</groupId>
        <artifactId>cglib-nodep</artifactId>
        <version>2.2</version>
      </dependency>
      <dependency>
        <groupId>org.objenesis</groupId>
        <artifactId>objenesis</artifactId>
        <version>1.2</version>
      </dependency>
      <dependency>
        <groupId>com.h2database</groupId>
        <artifactId>h2</artifactId>
        <version>1.2.147</version>
        <scope>runtime</scope>
      </dependency>
      <dependency>
        <groupId>org.apache.ant</groupId>
        <artifactId>ant</artifactId>
        <version>1.8.1</version> <!-- use same version as Groovy 1.8 -->
      </dependency>
      <dependency>
        <groupId>log4j</groupId>
        <artifactId>log4j</artifactId>
        <version>1.2.16</version>
      </dependency>
    </dependencies>
  </dependencyManagement>
                
  <repositories>
	<repository> <!-- for Groovy snapshots -->
	  <id>codehaus-snapshots</id>
	  <url>http://snapshots.repository.codehaus.org</url>    
	  <releases> 
		<enabled>false</enabled>
	  </releases>
	  <snapshots>
	  	<enabled>true</enabled>
	  </snapshots>
	</repository>
  </repositories>

  <distributionManagement>
    <repository>
      <id>spock-releases</id>
      <url>file:///var/www/m2repo/releases</url>
    </repository>
    <snapshotRepository>
      <id>spock-snapshots</id>
      <url>file:///var/www/m2repo/snapshots</url>
      <uniqueVersion>false</uniqueVersion>
    </snapshotRepository>
  </distributionManagement>

  <profiles>
    <profile>
      <id>default</id>
      <activation>
        <activeByDefault>true</activeByDefault>
      </activation>
      <modules>
        <module>spock-core</module>
        <module>spock-specs</module>
        <module>spock-maven</module>
        <module>spock-example</module>
        <module>spock-tapestry</module>
        <module>spock-guice</module>
        <module>spock-spring</module>
        <module>spock-unitils</module>  
      </modules>
    </profile>
    <profile>
      <id>sonar</id>
      <modules>
        <module>spock-core</module>
        <module>spock-specs</module>
        <module>spock-maven</module>
        <module>spock-example</module>
        <module>spock-tapestry</module>
        <module>spock-guice</module>
        <module>spock-spring</module>
        <module>spock-unitils</module>
      </modules>
      <properties>
        <sonar.jdbc.url>jdbc:mysql://localhost:3306/sonar?useUnicode=true&amp;characterEncoding=utf8</sonar.jdbc.url>
        <sonar.jdbc.driver>com.mysql.jdbc.Driver</sonar.jdbc.driver>
        <sonar.jdbc.username>sonar</sonar.jdbc.username>
        <sonar.jdbc.password>sonar</sonar.jdbc.password>
        <sonar.host.url>http://localhost:9123</sonar.host.url>
        <maven.test.failure.ignore>true</maven.test.failure.ignore>
      </properties>
    </profile>
    <profile>
      <id>release</id>
      <modules>
        <module>spock-core</module>
        <module>spock-specs</module>
        <module>spock-maven</module>
        <module>spock-example</module>
        <module>spock-tapestry</module>
        <module>spock-guice</module>
        <module>spock-spring</module>
        <module>spock-unitils</module>
      </modules>
      <build>
        <plugins>
          <plugin>
            <groupId>org.apache.maven.plugins</groupId>
            <artifactId>maven-release-plugin</artifactId>
            <version>2.1</version>
            <configuration>
              <remoteTagging>true</remoteTagging>
            </configuration>
          </plugin>
          <plugin>
            <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>
            <artifactId>maven-javadoc-plugin</artifactId>
            <version>2.7</version>
            <configuration>
              <links>
                <link>http://java.sun.com/j2se/1.5.0/docs/api</link>
                <link>http://groovy.codehaus.org/gapi</link>
                <link>http://static.springsource.org/spring/docs/2.5.x/api</link>
                <link>http://google-guice.googlecode.com/svn/trunk/javadoc</link>
                <link>http://tapestry.apache.org/tapestry5/apidocs</link>
              </links>
            </configuration>
            <executions>
              <execution>
                <id>attach-javadocs</id>
                <goals>
                  <goal>jar</goal>
                </goals>
              </execution>
            </executions>
          </plugin>
        </plugins>
      </build>
    </profile>
  </profiles>
</project>
