<?xml version="1.0"?>
<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>org.cristalise</groupId>
	<artifactId>cristalise-kernel</artifactId>
	<name>cristalise-kernel</name>
	<version>3.2</version>
	<description>Cristal-ise is a description-driven software platform originally developed to track the construction of 
	the CMS ECAL detector of the LHC at CERN. This is its core library, known as the kernel, which manages 
	business objects called Items. Items are entirely configured from data, called descriptions, held in other Items. 
	Every change of a state in an Item is a consequence of an execution of an activity in that Item's lifecycle, 
	meaning that Cristal-ise applications are completely traceable, even in their design. It also supports extensive 
	versioning of Item description data, giving the system a high level of flexibility.</description>
	<url>https://github.com/cristal-ise/kernel</url>
	<inceptionYear>1997</inceptionYear>
	<licenses>
		<license>
			<name>GNU Library or Lesser General Public License v3 (LGPL3)</name>
			<url>http://www.gnu.org/licenses/lgpl.html</url>
		</license>
	</licenses>
	<developers>
		<developer>
			<name>Andrew Branson</name>
			<email>andrew.branson@cern.ch</email>
			<organization>UWE CCCS</organization>
			<organizationUrl>http://www.cccs.uwe.ac.uk/et/research/cccs</organizationUrl>
			<roles>
				<role>CEO</role>
			</roles>
		</developer>
		<developer>
			<name>Jetendr Shamdasani</name>
			<email>jetendr.shamdasani@cern.ch</email>
			<organization>UWE CCCS</organization>
			<organizationUrl>http://www.cccs.uwe.ac.uk/et/research/cccs</organizationUrl>
			<roles>
				<role>CEO</role>
			</roles>
		</developer>
		<developer>
			<name>Zsolt Kovács</name>
			<email>zs.myth@gmail.com</email>
			<organization>UWE CCCS</organization>
			<organizationUrl>http://www.cccs.uwe.ac.uk/et/research/cccs</organizationUrl>
			<roles>
				<role>Pinky/Brain</role>
			</roles>
		</developer>
	</developers>
	<issueManagement>
		<url>https://github.com/cristal-ise/kernel/issues</url>
		<system>GitHub</system>
	</issueManagement>
	<organization>
		<name>CRISTAL-iSE</name>
		<url>http://cristal-ise.github.io/</url>
	</organization>
	<ciManagement>
		<system>Jenkins</system>
		<url>https://travis-ci.org/cristal-ise/kernel</url>
	</ciManagement>
	<scm>
		<developerConnection>scm:https://github.com/cristal-ise/kernel.git</developerConnection>
		<url>https://github.com/cristal-ise/kernel</url>
		<tag>master</tag>
	</scm>
	<mailingLists>
		<mailingList>
			<name>User List</name>
			<post>cristal-users@cern.ch</post>
			<subscribe>cristal-users-subscribe@cern.ch</subscribe>
			<unsubscribe>cristal-users-unsubscribe@cern.ch</unsubscribe>
			<archive>https://groups.cern.ch/group/cristal-users/default.aspx</archive>
		</mailingList>
	</mailingLists>
	<distributionManagement>
		<snapshotRepository>
			<id>ossrh</id>
			<url>https://oss.sonatype.org/content/repositories/snapshots</url>
		</snapshotRepository>
		<repository>
			<id>ossrh</id>
			<url>https://oss.sonatype.org/service/local/staging/deploy/maven2/</url>
		</repository>
	</distributionManagement>
	<properties>
		<project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
	</properties>

	<dependencies>
		<dependency>
			<groupId>org.codehaus.castor</groupId>
			<artifactId>castor-xml-schema</artifactId>
			<exclusions>
				<exclusion>
					<artifactId>stax</artifactId>
					<groupId>stax</groupId>
				</exclusion>
			</exclusions>
		</dependency>
		<dependency>
			<groupId>org.codehaus.castor</groupId>
			<artifactId>castor-xml</artifactId>
			<exclusions>
				<exclusion>
					<artifactId>stax</artifactId>
					<groupId>stax</groupId>
				</exclusion>
			</exclusions>
		</dependency>
		<dependency>
			<groupId>org.python</groupId>
			<artifactId>jython</artifactId>
			<scope>runtime</scope>
		</dependency>
		<dependency>
			<groupId>xmlunit</groupId>
			<artifactId>xmlunit</artifactId>
		</dependency>
		<dependency>
			<groupId>junit</groupId>
			<artifactId>junit</artifactId>
			<version>4.11</version>
			<scope>test</scope>
		</dependency>
		<dependency>
			<groupId>org.spockframework</groupId>
			<artifactId>spock-core</artifactId>
			<version>1.0-groovy-2.4</version>
			<scope>test</scope>
		</dependency>
		<dependency>
			<groupId>org.codehaus.groovy</groupId>
			<artifactId>groovy-all</artifactId>
			<version>2.4.3</version>
			<scope>test</scope>
		</dependency>
	</dependencies>

	<dependencyManagement>
		<dependencies>
			<dependency>
				<groupId>org.codehaus.castor</groupId>
				<artifactId>castor-xml-schema</artifactId>
				<version>1.3.2</version>
			</dependency>
			<dependency>
				<groupId>org.python</groupId>
				<artifactId>jython</artifactId>
				<version>2.5.3</version>
				<scope>runtime</scope>
			</dependency>
			<dependency>
				<groupId>xmlunit</groupId>
				<artifactId>xmlunit</artifactId>
				<version>1.5</version>
			</dependency>
			<dependency>
				<groupId>org.codehaus.castor</groupId>
				<artifactId>castor-xml</artifactId>
				<version>1.3.2</version>
			</dependency>
		</dependencies>
	</dependencyManagement>

	<build>
		<resources>
			<resource>
				<directory>src/main/resources</directory>
				<targetPath>org/cristalise/kernel/utils/resources</targetPath>
				<filtering>true</filtering>
			</resource>
			<resource>
				<directory>.</directory>
				<includes>
					<include>log4j.properties</include>
					<include>LICENSE</include>
				</includes>
				<targetPath>.</targetPath>
				<filtering>false</filtering>
			</resource>
		</resources>

		<pluginManagement>
			<plugins>
				<!--This plugin's configuration is used to store Eclipse m2e settings 
					only. It has no influence on the Maven build itself. -->
				<plugin>
					<groupId>org.eclipse.m2e</groupId>
					<artifactId>lifecycle-mapping</artifactId>
					<version>1.0.0</version>
					<configuration>
						<lifecycleMappingMetadata>
							<pluginExecutions>
								<pluginExecution>
									<pluginExecutionFilter>
										<groupId>org.codehaus.mojo</groupId>
										<artifactId>idlj-maven-plugin</artifactId>
										<versionRange>[1.1,)</versionRange>
										<goals>
											<goal>generate</goal>
										</goals>
									</pluginExecutionFilter>
									<action>
										<execute>
											<runOnIncremental>false</runOnIncremental>
										</execute>
									</action>
								</pluginExecution>
								<pluginExecution>
									<pluginExecutionFilter>
										<groupId>org.codehaus.gmavenplus</groupId>
										<artifactId>gmavenplus-plugin</artifactId>
										<versionRange>[1.5,)</versionRange>
										<goals>
											<goal>testGenerateStubs</goal>
											<goal>removeTestStubs</goal>
											<goal>testCompile</goal>
										</goals>
									</pluginExecutionFilter>
									<action>
										<ignore/>
									</action>
								</pluginExecution>
							</pluginExecutions>
						</lifecycleMappingMetadata>
					</configuration>
				</plugin>
			</plugins>
		</pluginManagement>

		<plugins>
			<plugin>
				<groupId>org.codehaus.mojo</groupId>
				<artifactId>idlj-maven-plugin</artifactId>
				<version>1.1</version>
				<executions>
					<execution>
						<goals>
							<goal>generate</goal>
						</goals>
					</execution>
				</executions>
				<configuration>
					<compiler>idlj</compiler>
					<sources>
						<source>
							<includes>
								<include>*.idl</include>
							</includes>
							<packagePrefixes>
								<packagePrefix>
									<type>common</type>
									<prefix>org.cristalise.kernel</prefix>
								</packagePrefix>
								<packagePrefix>
									<type>entity</type>
									<prefix>org.cristalise.kernel</prefix>
								</packagePrefix>
							</packagePrefixes>
							<compatible>false</compatible>
						</source>
					</sources>
				</configuration>
			</plugin>
			<plugin>
				<artifactId>maven-compiler-plugin</artifactId>
				<version>2.3.2</version>
				<configuration>
					<source>1.7</source>
					<target>1.7</target>
				</configuration>
			</plugin>
			<plugin>
				<groupId>org.codehaus.mojo</groupId>
				<artifactId>build-helper-maven-plugin</artifactId>
				<version>1.7</version>
				<executions>
					<execution>
						<id>add-source</id>
						<phase>generate-sources</phase>
						<goals>
							<goal>add-source</goal>
						</goals>
						<configuration>
							<sources>
								<source>${project.build.directory}/generated-sources/idl/</source>
							</sources>
						</configuration>
					</execution>
				</executions>
			</plugin>
			<plugin>
				<groupId>org.apache.maven.plugins</groupId>
				<artifactId>maven-source-plugin</artifactId>
				<version>2.4</version>
				<executions>
					<execution>
						<id>attach-sources</id>
						<phase>verify</phase>
						<goals>
							<goal>jar-no-fork</goal>
							<goal>test-jar-no-fork</goal>
						</goals>
					</execution>
				</executions>
			</plugin>
			<plugin>
				<groupId>org.apache.maven.plugins</groupId>
				<artifactId>maven-javadoc-plugin</artifactId>
				<version>2.9.1</version>
				<executions>
					<execution>
						<id>attach-javadocs</id>
						<goals>
							<goal>jar</goal>
						</goals>
					</execution>
				</executions>		
			</plugin>
			<plugin>
				<groupId>org.apache.maven.plugins</groupId>
				<artifactId>maven-release-plugin</artifactId>
				<version>2.4.1</version>
			</plugin>
			<plugin>
				<groupId>com.mycila</groupId>
				<artifactId>license-maven-plugin</artifactId>
				<version>2.3</version>
				<configuration>
					<header>HEADER.txt</header>
					<excludes>
						<exclude>pom.xml</exclude>
						<exclude>src/main/resources/textFiles/**</exclude>
						<exclude>bin/**</exclude>
						<exclude>src/main/resources/boot/allbootitems.txt</exclude>
					</excludes>
					<mapping>
						<idl>JAVADOC_STYLE</idl>
					</mapping>
				</configuration>
				<executions>
					<execution>
						<goals>
							<goal>check</goal>
						</goals>
					</execution>
				</executions>
			</plugin>
			<plugin>
				<groupId>org.codehaus.gmavenplus</groupId>
				<artifactId>gmavenplus-plugin</artifactId>
				<version>1.5</version>
				<executions>
					<execution>
						<goals>
							<goal>testGenerateStubs</goal>
							<goal>testCompile</goal>
							<goal>removeTestStubs</goal>
						</goals>
					</execution>
				</executions>
			</plugin>
			<plugin>
				<artifactId>maven-surefire-plugin</artifactId>
				<version>2.18</version>
				<configuration>
					<includes>
						<include>**/*Specs.*</include>
						<include>**/*Tests.*</include>
						<include>**/*Test.java</include>
					</includes>
				</configuration>
			</plugin>
		</plugins>
	</build>
	
    <profiles>
        <profile>
            <id>ossrh</id>
            <properties>
                <gpg.executable>gpg</gpg.executable>
                <gpg.keyname>${env.GPG_KEYNAME}</gpg.keyname>
                <gpg.passphrase>${env.GPG_PASSPHRASE}</gpg.passphrase>
                <gpg.defaultKeyring>false</gpg.defaultKeyring>
                <gpg.publicKeyring>${env.GPG_DIR}/pubring.gpg</gpg.publicKeyring>
                <gpg.secretKeyring>${env.GPG_DIR}/secring.gpg</gpg.secretKeyring>
            </properties>
            <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.5</version>
                        <executions>
                            <execution>
                                <id>sign-artifacts</id>
                                <phase>verify</phase>
                                <goals>
                                    <goal>sign</goal>
                                </goals>
                            </execution>
                        </executions>
                    </plugin>
                    <plugin>
                        <groupId>org.sonatype.plugins</groupId>
                        <artifactId>nexus-staging-maven-plugin</artifactId>
                        <version>1.6.2</version>
                        <extensions>true</extensions>
                        <configuration>
                            <serverId>ossrh</serverId>
                            <nexusUrl>https://oss.sonatype.org/</nexusUrl>
                            <autoReleaseAfterClose>true</autoReleaseAfterClose>
                        </configuration>
                    </plugin>
                </plugins>
            </build>
        </profile>
    </profiles>	
</project>
