<?xml version="1.0" encoding="UTF-8"?>

<!--
  ~ Copyright (c) 2010-2013 Evolveum
  ~
  ~ Licensed under the Apache License, Version 2.0 (the "License");
  ~ you may not use this file except in compliance with the License.
  ~ You may obtain a copy of the License at
  ~
  ~     http://www.apache.org/licenses/LICENSE-2.0
  ~
  ~ Unless required by applicable law or agreed to in writing, software
  ~ distributed under the License is distributed on an "AS IS" BASIS,
  ~ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
  ~ See the License for the specific language governing permissions and
  ~ limitations under the License.
  -->

<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>
    <name>midPoint Distribution</name>
    <artifactId>dist</artifactId>
    <packaging>pom</packaging>
    <parent>
        <artifactId>parent</artifactId>
        <groupId>com.evolveum.midpoint</groupId>
        <version>3.3.1</version>
        <relativePath>../build-system/pom.xml</relativePath>
    </parent>
    <organization>
        <name>Evolveum</name>
        <url>http://www.evolveum.com</url>
    </organization>
    <licenses>
        <license>
            <name>Apache License v2.0</name>
            <url>http://www.apache.org/licenses/LICENSE-2.0.txt</url>
            <distribution>repo</distribution>
        </license>
    </licenses>
    <issueManagement>
        <system>Atlassian JIRA</system>
        <url>http://jira.evolveum.com/</url>
    </issueManagement>
    <scm>
        <connection>https://github.com/Evolveum/midpoint.git</connection>
        <developerConnection>git@github.com:Evolveum/midpoint.git</developerConnection>
        <url>https://fisheye.evolveum.com/browse/midPoint</url>
    </scm>
    <dependencies>
   		<dependency>
            <groupId>com.evolveum.midpoint.gui</groupId>
            <artifactId>admin-gui</artifactId>
            <version>3.3.1</version>
            <type>war</type>
        </dependency>
        <dependency>
            <groupId>com.evolveum.midpoint.tools</groupId>
            <artifactId>repo-ninja</artifactId>
            <version>3.3.1</version>
            <type>zip</type>
            <classifier>bin</classifier>
        </dependency>
        <dependency>
            <groupId>com.evolveum.midpoint.tools</groupId>
            <artifactId>repo-ninja</artifactId>
            <version>3.3.1</version>
        </dependency> 
    	<dependency><!-- Not used, but required for surefire plugin not to complain -->
            <groupId>org.testng</groupId>
            <artifactId>testng</artifactId>
            <scope>test</scope>
        </dependency>
    </dependencies>
    <build>
        <plugins>
            <plugin>
                <!-- Used to pull XSD files from the JAR -->
                <groupId>com.evolveum.midpoint.tools</groupId>
                <artifactId>schema-dist-maven-plugin</artifactId>
                <executions>
                    <execution>
                        <id>schemadist-prism</id>
                        <phase>initialize</phase>
                        <goals>
                            <goal>schemadist</goal>
                        </goals>
                        <configuration>
                            <artifactItems>
                                <artifactItem>
                                    <groupId>com.evolveum.midpoint.infra</groupId>
                                    <artifactId>prism</artifactId>
                                    <version>${project.version}</version>
                                    <type>jar</type>
                                    <catalog>META-INF/catalog-runtime.xml</catalog>
                                </artifactItem>
                                <artifactItem>
                                    <groupId>com.evolveum.midpoint.infra</groupId>
                                    <artifactId>schema</artifactId>
                                    <version>${project.version}</version>
                                    <type>jar</type>
                                    <catalog>META-INF/jax-ws-catalog.xml</catalog>
                                </artifactItem>
                            </artifactItems>
                            <includes>**/*.xsd,**/*.dtd,**/*.wsdl,META-INF/*</includes>
                            <excludes>xml/ns/test/**,xml/ns/private/**,prism/**</excludes>
                            <outputDirectory>${project.basedir}/target/schemadist</outputDirectory>
                        </configuration>
                    </execution>
                </executions>
            </plugin>
            <plugin>
		        <artifactId>maven-assembly-plugin</artifactId>
		        <version>2.4</version>
		        <configuration>
		          <descriptors>
		            <descriptor>src/main/assembly/dist.xml</descriptor>
		          </descriptors>
		          <finalName>midpoint-${version}</finalName>
		        </configuration>
		        <executions>
		          <execution>
		            <id>make-assembly</id> <!-- this is used for inheritance merges -->
		            <phase>package</phase> <!-- bind to the packaging phase -->
		            <goals>
		              <goal>single</goal>
		            </goals>
		          </execution>
		        </executions>
	        </plugin>
        </plugins>
    </build>
    <modules>
        <module>midpoint-api</module>
    </modules>
</project>
