<?xml version="1.0" encoding="UTF-8"?>
<!--
  JBoss, Home of Professional Open Source
  Copyright Red Hat, Inc., and individual contributors

  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/maven-v4_0_0.xsd">
    <modelVersion>4.0.0</modelVersion>

    <groupId>org.jboss.aerogear</groupId>
    <artifactId>aerogear-android-push</artifactId>
    <version>4.0.2</version>
    <packaging>aar</packaging>
    <name>AeroGear Android Push Library</name>
    <url>http://aerogear.org</url>

    <parent>
        <groupId>org.jboss.aerogear</groupId>
        <artifactId>aerogear-android-push-parent</artifactId>
        <version>4.0.2</version>
    </parent>

    <scm>
        <connection>scm:git:git@github.com:aerogear/aerogear-android-push.git</connection>
        <developerConnection>scm:git:git@github.com:aerogear/aerogear-android-push.git</developerConnection>
        <url>git@github.com:aerogear/aerogear-android-push.git</url>
        <tag>4.0.2</tag>
    </scm>

    <properties>

        <!-- Dependencies versions -->
        <aerogear.android.core.version>3.0.0</aerogear.android.core.version>
        <aerogear.android.pipe.version>3.0.0</aerogear.android.pipe.version>
        <firebase.version>9.4.0</firebase.version>

        <!-- Plugins versions -->
        <maven.javadoc.plugin.version>2.10.3</maven.javadoc.plugin.version>
        <builder.helper.plugin.version>1.10</builder.helper.plugin.version>

    </properties>

    <dependencies>
        
        <dependency>
            <groupId>org.jboss.aerogear</groupId>
            <artifactId>aerogear-android-core</artifactId>
            <version>3.0.0</version>
            <type>aar</type>
        </dependency>

        <dependency>
            <groupId>org.jboss.aerogear</groupId>
            <artifactId>aerogear-android-core</artifactId>
            <version>3.0.0</version>
            <type>jar</type>
            <scope>provided</scope>
        </dependency>        

        <dependency>
            <groupId>org.jboss.aerogear</groupId>
            <artifactId>aerogear-android-pipe</artifactId>
            <version>${aerogear.android.pipe.version}</version>
            <type>aar</type>
        </dependency>

        <dependency>
            <groupId>org.jboss.aerogear</groupId>
            <artifactId>aerogear-android-pipe</artifactId>
            <version>${aerogear.android.pipe.version}</version>
            <type>jar</type>
            <scope>provided</scope>
        </dependency>        


        <dependency>
            <groupId>com.google.firebase</groupId>
            <artifactId>firebase-messaging</artifactId>
            <version>${firebase.version}</version>
            <type>aar</type>
            <exclusions>
                <exclusion>
                    <groupId>com.android.support</groupId>
                    <artifactId>support-v4</artifactId>
                </exclusion>
            </exclusions>
        </dependency>
        
        <dependency>
            <groupId>com.google.code.gson</groupId>
            <artifactId>gson</artifactId>
        </dependency>

    </dependencies>

    <build>
        <plugins>
            <plugin>
                <groupId>com.simpligility.maven.plugins</groupId>
                <artifactId>android-maven-plugin</artifactId>
                <configuration>
                    <run>
                        <debug>${android.debug}</debug>
                    </run>
                    <sdk>
                        <platform>${android.platform}</platform>
                    </sdk>
                    <proguard>
                        <skip>${proguard.skip}</skip>
                    </proguard>
                </configuration>
            </plugin>

            <plugin>
                <groupId>org.apache.maven.plugins</groupId>
                <artifactId>maven-compiler-plugin</artifactId>
                <configuration>
                    <source>${maven.compiler.source}</source>
                    <target>${maven.compiler.target}</target>
                </configuration>
            </plugin>

            <plugin>
                <groupId>org.apache.maven.plugins</groupId>
                <artifactId>maven-javadoc-plugin</artifactId>
                <version>${maven.javadoc.plugin.version}</version>
                <executions>
                    <execution>
                        <id>attach-sources</id>
                        <goals>
                            <goal>jar</goal>
                        </goals>
                    </execution>
                </executions>
                <configuration>
                    <sourcepath>${basedir}/src</sourcepath>
                    <sourceFileExcludes>
                        <exclude>
                            **com/google/**
                        </exclude>
                        <exclude>**/R.java</exclude>
                    </sourceFileExcludes>
                </configuration>
            </plugin>

            <plugin>
                <groupId>org.codehaus.mojo</groupId>
                <artifactId>build-helper-maven-plugin</artifactId>
                <version>${builder.helper.plugin.version}</version>
                <executions>
                    <execution>
                        <phase>package</phase>
                        <goals>
                            <goal>attach-artifact</goal>
                        </goals>
                        <configuration>
                            <artifacts>
                                <artifact>
                                    <type>jar</type>
                                    <file>${project.build.directory}/${project.build.finalName}.jar</file>
                                </artifact>
                            </artifacts>
                        </configuration>
                    </execution>
                </executions>
            </plugin>
        </plugins>
    </build>

</project>

