<!--
  ~ JBoss, Home of Professional Open Source
  ~ Copyright 2011 Red Hat Inc. and/or its affiliates and other contributors
  ~ as indicated by the @author tags. All rights reserved.
  ~ See the copyright.txt in the distribution for a
  ~ full listing of individual contributors.
  ~
  ~ This copyrighted material is made available to anyone wishing to use,
  ~ modify, copy, or redistribute it subject to the terms and conditions
  ~ of the GNU Lesser General Public License, v. 2.1.
  ~ This program is distributed in the hope that it will be useful, but WITHOUT A
  ~ WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A
  ~ PARTICULAR PURPOSE.  See the GNU Lesser General Public License for more details.
  ~ You should have received a copy of the GNU Lesser General Public License,
  ~ v.2.1 along with this distribution; if not, write to the Free Software
  ~ Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston,
  ~ MA  02110-1301, USA.
  -->
<project xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns="http://maven.apache.org/POM/4.0.0"
         xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/maven-v4_0_0.xsd">

    <parent>
        <groupId>org.jboss.as</groupId>
        <artifactId>jboss-as-console-build</artifactId>
        <version>2.8.18.Final</version>
        <relativePath/>
    </parent>

    <modelVersion>4.0.0</modelVersion>
    <groupId>org.jboss.hal</groupId>
    <artifactId>release-stream</artifactId>
    <version>2.8.19.Final</version>
    <packaging>war</packaging>
    <name>HAL Release Stream</name>
    <description>HAL release stream master. Implements the assembly.</description>

    <scm>
        <connection>scm:git:git://https://github.com/hal/release-stream.git</connection>
        <developerConnection>scm:git:git@github.com:hat/release-stream.git</developerConnection>
        <url>https://github.com/hal/release-stream</url>
    </scm>

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

        <!-- Assembly -->
        <assembly.id>overlay</assembly.id>
        <classifier>resources</classifier>
        <module.slot>main</module.slot>

        <!-- Extensions -->
        <!--<extension.picketlink.version>2.0.8.Final</extension.picketlink.version>-->
        <!--<extension.switchyard.version>1.0.0.Final</extension.switchyard.version>-->
        <!--<extension.teiid.version>2.5.2-SNAPSHOT</extension.teiid.version>-->
    </properties>

    <dependencies>
        <!-- PicketLink -->
        <!--
        <dependency>
            <groupId>org.picketlink</groupId>
            <artifactId>picketlink-console-extensions</artifactId>
            <version>${extension.picketlink.version}</version>
            <scope>provided</scope>
        </dependency>
        <dependency>
            <groupId>org.picketlink</groupId>
            <artifactId>picketlink-console-extensions</artifactId>
            <version>${extension.picketlink.version}</version>
            <classifier>sources</classifier>
            <scope>provided</scope>
        </dependency>
        -->

        <!-- SwitchYard -->
        <!--
        <dependency>
            <groupId>org.switchyard.console</groupId>
            <artifactId>switchyard-console-extension</artifactId>
            <version>${extension.switchyard.version}</version>
            <scope>provided</scope>
        </dependency>
        <dependency>
            <groupId>org.switchyard.console</groupId>
            <artifactId>switchyard-console-extension</artifactId>
            <version>${extension.switchyard.version}</version>
            <classifier>sources</classifier>
            <scope>provided</scope>
        </dependency>
        -->

        <!-- Teiid -->
        <!--
        <dependency>
            <groupId>org.jboss.teiid.web-console</groupId>
            <artifactId>console-extensions</artifactId>
            <version>${extension.teiid.version}</version>
            <scope>provided</scope>
        </dependency>
        <dependency>
            <groupId>org.jboss.teiid.web-console</groupId>
            <artifactId>console-extensions</artifactId>
            <version>${extension.teiid.version}</version>
            <classifier>sources</classifier>
            <scope>provided</scope>
        </dependency>
        -->
    </dependencies>

    <build>
        <finalName>hal-console-${project.version}</finalName>
        <pluginManagement>
            <plugins>
                <plugin>
                    <groupId>org.apache.maven.plugins</groupId>
                    <artifactId>maven-assembly-plugin</artifactId>
                    <version>2.4</version>
                </plugin>
                <plugin>
                    <groupId>org.apache.maven.plugins</groupId>
                    <artifactId>maven-clean-plugin</artifactId>
                    <version>2.5</version>
                </plugin>
                <plugin>
                    <groupId>org.apache.maven.plugins</groupId>
                    <artifactId>maven-enforcer-plugin</artifactId>
                    <version>1.2</version>
                </plugin>
                <plugin>
                    <groupId>org.apache.maven.plugins</groupId>
                    <artifactId>maven-jar-plugin</artifactId>
                    <version>2.4</version>
                </plugin>
            </plugins>
        </pluginManagement>

        <plugins>
            <plugin>
                <groupId>org.bsc.maven</groupId>
                <artifactId>maven-processor-plugin</artifactId>
                <executions>
                    <execution>
                        <id>process-spi</id>
                        <goals>
                            <goal>process</goal>
                        </goals>
                        <phase>generate-sources</phase>
                        <configuration>
                            <options>
                                <!--
                                    All properties prefixed with 'gwt.' are written into the
                                    generated GWT module (without the 'gwt.' prefix)
                                -->
                                <gwt.hal.version>${project.version}</gwt.hal.version>
                                <gwt.console.core.version>${project.parent.version}</gwt.console.core.version>
                                <!-- Uncomment to get more messages from the annotation processors -->
                                <!--<debug>true</debug>-->
                            </options>
                            <processSourceArtifacts>
                                <processSourceArtifact>org.jboss.as:jboss-as-console-core:sources</processSourceArtifact>
                                <!--<processSourceArtifact>org.picketlink:picketlink-console-extensions</processSourceArtifact>-->
                                <!--<processSourceArtifact>org.picketlink:picketlink-console-extensions</processSourceArtifact>-->
                                <!--<processSourceArtifact>org.jboss.teiid.web-console:console-extensions:sources</processSourceArtifact>-->
                            </processSourceArtifacts>
                            <defaultOutputDirectory>${project.build.directory}/generated-sources/annotations</defaultOutputDirectory>
                        </configuration>
                    </execution>
                </executions>
            </plugin>
            <plugin>
                <groupId>org.apache.maven.plugins</groupId>
                <artifactId>maven-compiler-plugin</artifactId>
                <configuration>
                    <compilerArgument>-proc:none</compilerArgument>
                </configuration>
            </plugin>
            <plugin>
                <groupId>org.apache.maven.plugins</groupId>
                <artifactId>maven-assembly-plugin</artifactId>
                <configuration>
                    <descriptors>
                        <descriptor>src/main/assembly/overlay.xml</descriptor>
                    </descriptors>
                </configuration>
                <executions>
                    <execution>
                        <id>=~=~=~=~= Assembly for :: HAL Console ${project.version} (slot ${module.slot}):: =~=~=~=~=</id>
                        <phase>package</phase>
                        <goals>
                            <goal>single</goal>
                        </goals>
                    </execution>
                </executions>
            </plugin>
            <plugin>
                <groupId>org.apache.maven.plugins</groupId>
                <artifactId>maven-clean-plugin</artifactId>
                <configuration>
                    <filesets>
                        <fileset>
                            <directory>war</directory>
                            <includes>
                                <include>**/*.*</include>
                            </includes>
                        </fileset>
                        <fileset>
                            <directory>gwt-unitCache</directory>
                        </fileset>
                    </filesets>
                </configuration>
            </plugin>
            <plugin>
                <groupId>org.apache.maven.plugins</groupId>
                <artifactId>maven-jar-plugin</artifactId>
                <executions>
                    <execution>
                        <goals>
                            <goal>jar</goal>
                        </goals>
                        <phase>prepare-package</phase>
                    </execution>
                </executions>
                <configuration>
                    <classesDirectory>war</classesDirectory>
                    <excludes>
                        <exclude>WEB-INF/**</exclude>
                    </excludes>
                    <classifier>${classifier}</classifier>
                </configuration>
            </plugin>
            <plugin>
                <groupId>org.apache.maven.plugins</groupId>
                <artifactId>maven-enforcer-plugin</artifactId>
                <version>1.2</version>
                <executions>
                    <execution>
                        <id>enforce-versions</id>
                        <goals>
                            <goal>enforce</goal>
                        </goals>
                        <configuration>
                            <rules>
                                <requireJavaVersion>
                                    <version>[1.8,]</version>
                                    <message>*** The build works with JDK 8 only! ***</message>
                                </requireJavaVersion>
                            </rules>
                        </configuration>
                    </execution>
                </executions>
            </plugin>
        </plugins>
    </build>

    <profiles>
        <profile>
            <id>product</id>
            <properties>
                <module.slot>eap</module.slot>
            </properties>
        </profile>
        <profile>
            <id>full</id>
            <properties>
                <assembly.id>full-overlay</assembly.id>
                <classifier>full-resources</classifier>
            </properties>
        </profile>
    </profiles>

    <repositories>
        <repository>
            <id>jboss-public-repository-group</id>
            <name>JBoss Public Maven Repository Group</name>
            <url>https://repository.jboss.org/nexus/content/groups/public/</url>
            <layout>default</layout>
            <releases>
                <updatePolicy>never</updatePolicy>
            </releases>
            <snapshots>
                <updatePolicy>never</updatePolicy>
            </snapshots>
        </repository>
    </repositories>


    <distributionManagement>
        <repository>
            <id>jboss-releases-repository</id>
            <name>JBoss Releases Repository</name>
            <url>https://repository.jboss.org/nexus/service/local/staging/deploy/maven2/</url>
        </repository>
        <snapshotRepository>
            <id>jboss-snapshots-repository</id>
            <name>JBoss Snapshots Repository</name>
            <url>https://repository.jboss.org/nexus/content/repositories/snapshots/</url>
        </snapshotRepository>
    </distributionManagement>
</project>
