<?xml version="1.0" encoding="UTF-8"?>
<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.mule</groupId>
    <artifactId>mule-maven-client</artifactId>
    <packaging>pom</packaging>
    <version>1.0.0-BETA.3</version>
    <name>Mule Maven Client Parent</name>
    <description>Parenet project for mule maven client</description>

    <organization>
        <name>MuleSoft, Inc.</name>
        <url>http://www.mulesoft.com</url>
    </organization>
    <licenses>
        <license>
            <name>CPAL v1.0</name>
            <url>http://www.mulesoft.com/CPAL</url>
        </license>
    </licenses>
    <mailingLists>
        <mailingList>
            <name>developers</name>
            <post>mule-esb@mulesoft.com</post>
        </mailingList>
    </mailingLists>

    <developers>
        <developer>
            <id>canoasan</id>
            <name>Matias Baldini</name>
            <email>matias.baldini@mulesoft.com</email>
            <roles>
                <role>Project Manager</role>
            </roles>
        </developer>
        <developer>
            <id>pablolagreca</id>
            <name>Pablo La Greca</name>
        </developer>
        <developer>
            <id>gsfernandes</id>
            <name>Guillermo Fernandes</name>
        </developer>
    </developers>
    <issueManagement>
        <system>jira</system>
        <url>http://www.mulesoft.org/jira/browse/MULE</url>
    </issueManagement>

    <scm>
        <connection>scm:git:git://github.com/mulesoft/mule-maven-client.git</connection>
        <developerConnection>scm:git:git@github.com:mulesoft/mule-maven-client.git</developerConnection>
        <url>https://github.com/mulesoft/mule-maven-client</url>
    </scm>

    <modules>
        <module>mule-maven-client-api</module>
        <module>mule-maven-client-impl</module>
        <module>mule-maven-client-test</module>
    </modules>

    <properties>
        <mavenCompilerVersion>3.5.1</mavenCompilerVersion>
        <javaVersion>1.8</javaVersion>
        <checkstyle.plugin.version>2.17</checkstyle.plugin.version>
        <javaFormatter.plugin.version>1.8.0</javaFormatter.plugin.version>
        <license.maven.plugin.version>2.11</license.maven.plugin.version>
        <formatterConfigPath>formatter.xml</formatterConfigPath>
        <formatterGoal>validate</formatterGoal>
        <skipVerifications>false</skipVerifications>
        <project.build.sourceEncoding>ISO-8859-1</project.build.sourceEncoding>
        <aether.version>1.0.2.v20150114</aether.version>
        <maven.version>3.3.9</maven.version>
        <commons.io.version>2.5</commons.io.version>
        <slf4jVersion>1.7.24</slf4jVersion>
        <formatterConfigPath>formatter.xml</formatterConfigPath>
        <jcommander.version>1.69</jcommander.version>
    </properties>

    <build>
        <plugins>
            <plugin>
                <groupId>org.apache.maven.plugins</groupId>
                <artifactId>maven-compiler-plugin</artifactId>
                <version>${mavenCompilerVersion}</version>
                <configuration>
                    <encoding>ISO-8859-1</encoding>
                    <fork>true</fork>
                    <maxmem>512m</maxmem>
                    <source>${javaVersion}</source>
                    <target>${javaVersion}</target>
                    <proc>none</proc>
                    <!-- Slightly faster builds, see https://jira.codehaus.org/browse/MCOMPILER-209 -->
                    <useIncrementalCompilation>false</useIncrementalCompilation>
                </configuration>
            </plugin>
            <plugin>
                <groupId>org.apache.maven.plugins</groupId>
                <artifactId>maven-checkstyle-plugin</artifactId>
                <version>${checkstyle.plugin.version}</version>
            </plugin>
            <plugin>
                <groupId>com.marvinformatics.formatter</groupId>
                <artifactId>formatter-maven-plugin</artifactId>
                <version>${javaFormatter.plugin.version}</version>
                <configuration>
                    <compilerCompliance>${javaVersion}</compilerCompliance>
                    <compilerSource>${javaVersion}</compilerSource>
                    <compilerTargetPlatform>${javaVersion}</compilerTargetPlatform>
                    <configFile>${basedir}/${formatterConfigPath}</configFile>
                    <configJsFile>${basedir}/${formatterConfigPath}</configJsFile>
                    <lineEnding>LF</lineEnding>
                    <aggregator>false</aggregator>
                    <executionRoot>true</executionRoot>
                </configuration>
                <executions>
                    <execution>
                        <id>apply-format</id>
                        <phase>compile</phase>
                        <goals>
                            <goal>${formatterGoal}</goal>
                        </goals>
                        <configuration>
                            <skipFormatting>${skipVerifications}</skipFormatting>
                        </configuration>
                    </execution>
                </executions>
            </plugin>
            <plugin>
                <groupId>com.mycila</groupId>
                <artifactId>license-maven-plugin</artifactId>
                <version>${license.maven.plugin.version}</version>
                <configuration>
                    <skip>${skipVerifications}</skip>
                    <header>com/mycila/maven/plugin/license/templates/CPAL.txt</header>
                    <properties>
                        <owner>MuleSoft, Inc</owner>
                        <project.url>http://www.mulesoft.com</project.url>
                    </properties>
                    <includes>
                        <include>**/*.java</include>
                    </includes>
                    <mapping>
                        <java>SLASHSTAR_STYLE</java>
                    </mapping>
                </configuration>
                <executions>
                    <execution>
                        <phase>compile</phase>
                        <goals>
                            <goal>check</goal>
                        </goals>
                    </execution>
                </executions>
            </plugin>
        </plugins>
    </build>

    <distributionManagement>
        <downloadUrl>http://www.mulesoft.org/display/MULE/Download</downloadUrl>
        <repository>
            <id>mule-releases</id>
            <name>Mule Release Repository</name>
            <url>https://repository-master.mulesoft.org/nexus/content/repositories/releases</url>
        </repository>
        <snapshotRepository>
            <id>mule-snapshots</id>
            <name>Mule Snapshot Repository</name>
            <url>https://repository-master.mulesoft.org/nexus/content/repositories/snapshots</url>
            <uniqueVersion>false</uniqueVersion>
        </snapshotRepository>
    </distributionManagement>

    <repositories>
        <repository>
            <id>mule</id>
            <name>Mule Repository</name>
            <url>https://repository.mulesoft.org/nexus/content/repositories/public/</url>
        </repository>
    </repositories>

    <profiles>
        <profile>
            <id>release</id>
            <properties>
                <skipVerifications>false</skipVerifications>
                <skipGpg>false</skipGpg>
            </properties>
            <build>
                <plugins>
                    <plugin>
                        <groupId>org.apache.maven.plugins</groupId>
                        <artifactId>maven-javadoc-plugin</artifactId>
                        <executions>
                            <execution>
                                <id>attach-javadocs</id>
                                <goals>
                                    <goal>jar</goal>
                                </goals>
                            </execution>
                        </executions>
                        <configuration>
                            <additionalparam>${xDocLint}</additionalparam>
                        </configuration>
                    </plugin>
                    <plugin>
                        <groupId>org.apache.maven.plugins</groupId>
                        <artifactId>maven-source-plugin</artifactId>
                        <executions>
                            <execution>
                                <id>attach-sources</id>
                                <goals>
                                    <goal>jar</goal>
                                    <goal>test-jar</goal>
                                </goals>
                            </execution>
                        </executions>
                    </plugin>
                    <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>
                        <configuration>
                            <skip>${skipGpg}</skip>
                        </configuration>
                    </plugin>
                </plugins>
            </build>
        </profile>
        <profile>
            <id>allure</id>
            <build>
                <pluginManagement>
                    <plugins>
                        <plugin>
                            <groupId>org.apache.maven.plugins</groupId>
                            <artifactId>maven-surefire-plugin</artifactId>
                            <configuration>
                                <testFailureIgnore>true</testFailureIgnore>
                                <argLine>
                                    -javaagent:${settings.localRepository}/org/aspectj/aspectjweaver/${aspectjVersion}/aspectjweaver-${aspectjVersion}.jar
                                </argLine>
                                <properties>
                                    <property>
                                        <name>listener</name>
                                        <value>ru.yandex.qatools.allure.junit.AllureRunListener</value>
                                    </property>
                                </properties>
                                <systemPropertyVariables>
                                    <allure.profile.is.activated>true</allure.profile.is.activated>
                                </systemPropertyVariables>
                            </configuration>
                            <dependencies>
                                <dependency>
                                    <groupId>org.aspectj</groupId>
                                    <artifactId>aspectjweaver</artifactId>
                                    <version>${aspectjVersion}</version>
                                </dependency>
                            </dependencies>
                        </plugin>

                        <!--Needed only to show reports locally. Run jetty:run and open localhost:8080 to show the report-->
                        <plugin>
                            <groupId>org.eclipse.jetty</groupId>
                            <artifactId>jetty-maven-plugin</artifactId>
                            <version>${jetty.maven.plugin.version}</version>
                            <configuration>
                                <webAppSourceDirectory>${project.build.directory}/site/allure-maven-plugin</webAppSourceDirectory>
                                <stopKey>stop</stopKey>
                                <stopPort>1234</stopPort>
                            </configuration>
                        </plugin>
                    </plugins>
                </pluginManagement>
            </build>

            <reporting>
                <excludeDefaults>true</excludeDefaults>
                <plugins>
                    <plugin>
                        <groupId>ru.yandex.qatools.allure</groupId>
                        <artifactId>allure-maven-plugin</artifactId>
                        <version>${allure.maven.plugin.version}</version>
                    </plugin>
                </plugins>
            </reporting>
        </profile>

    </profiles>

</project>
