<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>
  
  <!-- Shared parent project definition for Day Management AG -->
  <groupId>com.day</groupId>
  <artifactId>day</artifactId>
  <version>7</version>
  <packaging>pom</packaging>
  <url>https://adobe.com</url>
  <licenses>
    <license>
      <name>License Agreement</name>
      <url>http://adobe.com/go/terms</url>
      <distribution>repo</distribution>
    </license>
  </licenses>
  <organization>
    <name>Adobe</name>
    <url>http://www.adobe.com/</url>
  </organization>
  <developers>
    <developer>
      <name>Adobe</name>
      <email>repo@adobe.com</email>
      <organization>Adobe</organization>
      <organizationUrl>http://www.adobe.com</organizationUrl>
    </developer>
  </developers>

  <name>Day Management AG</name>
  <description>
    This project definition contains the core definition for all Maven 2
    projects of Day Management AG such that we have a consistent project
    build environment and need not repeat common configuration everytime.

    Each parent project of the Day products should refer to this project
    (${project.groupId}:${project.artifactId}:${project.version}) as its
    parent. It is not intended for this project to be modified often.
    Hence use a simple counter as its version.
  </description>

  <!--
    The inception year is used to calculate the ${projectTimespan} property
    used in the automatically included license information. We set it here
    to the year when Day was founded, but projects can override this setting
    with a more recent year if appropriate.
  -->
  <inceptionYear>1993</inceptionYear>

  <!--
    SCM configuration must be maintained per-project. Use the below
    commented configuration as a hint on how to set configuration in your
    project.
    
    The reason for not providing a master configuration is, that we use
    the a subtree per product (e.g. cq, cq4, crx, osgi) in which the turnk,
    branches and tags folders resied. If we configure here, Maven 2 will
    add another level with the name of the product parent version below
    the given URL, which would be wrong of course.
  -->
  <scm>
    <connection>scm:svn:http://svn.day.com/repos/day/tags/day-7</connection>
    <developerConnection>scm:svn:http://svn.day.com/repos/day/tags/day-7</developerConnection>
    <url>http://svn.day.com/repos/day/tags/day-7</url>
  </scm>

  <!--
    Organization description of Day Management AG.
    This should not be overwritten by projects as it is certainly common
    to all products.
  -->


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

  <!--
    This definition forces inclusion of source library builds for
    repository deployment.
    
    It is discussable whether this actually makes sense. On the other hand
    it simplifies development if the source is readily available without
    having to checkout and refer to the source manually. Having the source
    in the repository also allows IDE configuration file builders of maven
    to download the source and refer to it.
  -->
  <build>
  
    <!-- Add the WebDAV extension to wagon to support WebDAV Deployment -->
    <extensions>
        <extension>
            <groupId>org.apache.maven.wagon</groupId>
            <artifactId>wagon-webdav</artifactId>
            <version>1.0-beta-2</version>
        </extension>
    </extensions>

    <!-- build the source libraries for deployment -->
    <plugins>
      <plugin>
        <groupId>org.apache.maven.plugins</groupId>
        <artifactId>maven-source-plugin</artifactId>
        <inherited>true</inherited>
<!--
        <executions>
          <execution>
            <goals>
              <goal>jar</goal>
           </goals>
         </execution>
       </executions>
-->
     </plugin>
     <plugin>
        <groupId>org.apache.maven.plugins</groupId>
        <artifactId>maven-enforcer-plugin</artifactId>
        <executions>
          <execution>
            <id>enforce-maven</id>
            <goals>
              <goal>enforce</goal>
            </goals>
            <configuration>
              <rules>
                <requireMavenVersion>
                  <version>[2.0.7,)</version>
                </requireMavenVersion>
              </rules>
            </configuration>
          </execution>
        </executions>
      </plugin>
      <plugin>
        <!--
          Use the remote resources plugin to automatically inject
          a META-INF/LICENSE file into the build. Project-specific
          license information is automatically included from the
          src/main/appended-resources/META-INF/LICENSE file if it
          exists. Projects that for some reason should not include
          this license metadata need to explicitly disable the
          remote resources plugin with the "skip" configuration option.
        -->
        <groupId>org.apache.maven.plugins</groupId>
        <artifactId>maven-remote-resources-plugin</artifactId>
        <executions>
          <execution>
            <goals>
              <goal>process</goal>
            </goals>
            <configuration>
              <resourceBundles>
                <resourceBundle>
                  com.day.commons:day-jar-resource-bundle:1.0
                </resourceBundle>
              </resourceBundles>
            </configuration>
          </execution>
        </executions>
      </plugin>
    </plugins>
    <pluginManagement>
        <plugins>
            <plugin>
                <groupId>org.apache.maven.plugins</groupId>
                <artifactId>maven-release-plugin</artifactId>
                <version>2.0-beta-8</version>
            </plugin>
            <plugin>
                <groupId>org.apache.maven.plugins</groupId>
                <artifactId>maven-enforcer-plugin</artifactId>
                <version>1.0-alpha-4</version>
            </plugin>
            <plugin>
                <groupId>org.apache.maven.plugins</groupId>
                <artifactId>maven-source-plugin</artifactId>
                <version>2.0.4</version>
            </plugin>
            <plugin>
                <groupId>org.apache.maven.plugins</groupId>
                <artifactId>maven-remote-resources-plugin</artifactId>
                <version>1.0</version>
            </plugin>
        </plugins>
    </pluginManagement>
  </build>

<!--
    Continuous integration is not correctly implemented here, but we should
    go for a solution or another to simplify our lives.
    
    Currently nightly builds are mainly manually controlled which is too
    much overhead and hand work hence unstability.
-->
    
  <ciManagement>
    <system>continuum</system>
    <url>http://continuum.dev.day.com/continuum</url>
    <notifiers>
      <notifier>
        <type>mail</type>
        <configuration>
          <address>fmeschbe@gmail.com</address>
        </configuration>
      </notifier>
    </notifiers>
  </ciManagement>

  <!--
    Deploy to the Maven Repositories using WebDAV URLs. This enables abstracting
    the real location of the repositories and better access control. Finally
    it mirrors read and write operations through the same mechanism.
    NOTE: To use these dav: URLs, the WebDAV extension to Maven Wagon must
    be declared in the build section above.
  -->
  <distributionManagement>
    <repository>
      <id>day-archiva-repository</id>
      <name>Day Development Releases</name>
      <url>dav:http://repo.dev.day.com/dev-releases</url>
    </repository>
    <snapshotRepository>
      <id>day-archiva-repository</id>
      <name>Day Development Snapshots</name>
      <url>dav:http://repo.dev.day.com/dev-snapshots</url>
      <uniqueVersion>false</uniqueVersion>
    </snapshotRepository>
    <site>
      <id>day-archiva-repository</id>
      <name>Day Project Documentation Sites</name>
      <url>dav:http://repo.dev.day.com/sites-deploy/day</url>
    </site>
  </distributionManagement>
</project>
