<?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>com.tesobe</groupId>
    <artifactId>API_Explorer</artifactId>
    <version>1.0</version>
    <packaging>war</packaging>
    <name>API Explorer</name>
    <inceptionYear>2015</inceptionYear>
    <properties>
        <scala.compiler>2.11.12</scala.compiler>
        <scala.version>2.11</scala.version>
        <lift.version>2.6.3</lift.version>
        <jetty.version>9.4.12.v20180830</jetty.version>
        <!-- Common plugin settings -->
        <project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
        <project.reporting.outputEncoding>${project.build.sourceEncoding}</project.reporting.outputEncoding>
        <!-- vscaladoc settings -->
        <maven.scaladoc.vscaladocVersion>1.2-m1</maven.scaladoc.vscaladocVersion>
        <vscaladoc.links.liftweb.pathsufix>scaladocs/</vscaladoc.links.liftweb.pathsufix>
        <vscaladoc.links.liftweb.baseurl>http://scala-tools.org/mvnsites/liftweb</vscaladoc.links.liftweb.baseurl>
    </properties>

    <repositories>
        <repository>
            <id>scala-tools.releases</id>
            <name>Scala-Tools Dependencies Repository for Releases</name>
            <url>https://oss.sonatype.org/content/groups/scala-tools/</url>
        </repository>
    <repository>
      <id>java.net.maven3</id>
      <name>java.net Maven3 Repository</name>
      <url>http://download.java.net/maven/3/</url>
    </repository>
        <repository>
            <id>scala-tools.snapshots</id>
            <name>Scala-Tools Dependencies Repository for Snapshots</name>
            <url>https://oss.sonatype.org/content/repositories/snapshots/</url>
        </repository>
        <!--fetch lift framework related dependencies-->
        <repository>
        <id>jboss-public-repository-group</id>
        <name>JBoss Public Repository Group</name>
        <url>http://repository.jboss.org/nexus/content/groups/public</url>
     </repository>
        
        <repository>
            <id>git-OpenBankProject</id>
            <name>OpenBankProject Git based repo</name>
            <url>https://raw.githubusercontent.com/OpenBankProject/OBP-M2-REPO/master/</url>
        </repository>
        <repository>
            <id>jitpack.io</id>
            <url>https://jitpack.io</url>
        </repository>
    </repositories>

    <pluginRepositories>
      <pluginRepository>
        <id>org.sonatype.oss.groups.public</id>
        <name>Sonatype Public</name>
        <url>https://oss.sonatype.org/content/groups/public</url>
      </pluginRepository>
    </pluginRepositories>

    <dependencies>
        <dependency>
            <groupId>ch.qos.logback</groupId>
            <artifactId>logback-classic</artifactId>
            <version>1.2.3</version>
        </dependency>
        <dependency>
            <groupId>net.liftweb</groupId>
            <artifactId>lift-mapper_${scala.version}</artifactId>
            <version>${lift.version}</version>
        </dependency>
        <dependency>
            <groupId>net.liftmodules</groupId>
            <artifactId>widgets_2.6_${scala.version}</artifactId>
            <version>1.4-SNAPSHOT</version>
        </dependency>
        <dependency>
            <groupId>javax.servlet</groupId>
            <artifactId>javax.servlet-api</artifactId>
            <version>3.1.0</version>
            <scope>provided</scope>
        </dependency>
        <dependency>
            <groupId>junit</groupId>
            <artifactId>junit</artifactId>
            <version>4.13.1</version>
            <scope>test</scope>
        </dependency>
        <dependency>
            <groupId>org.scalatest</groupId>
            <artifactId>scalatest_${scala.version}</artifactId>
            <version>2.2.6</version>
            <scope>test</scope>
        </dependency>
        <dependency>
            <groupId>org.eclipse.jetty</groupId>
            <artifactId>jetty-util</artifactId>
            <version>${jetty.version}</version>
        </dependency>
        <!-- https://mvnrepository.com/artifact/org.eclipse.jetty/jetty-server -->
        <dependency>
            <groupId>org.eclipse.jetty</groupId>
            <artifactId>jetty-server</artifactId>
            <version>${jetty.version}</version>
            <scope>test</scope>
        </dependency>
        <!-- https://mvnrepository.com/artifact/org.eclipse.jetty.websocket/websocket-server -->
        <dependency>
            <groupId>org.eclipse.jetty</groupId>
            <artifactId>jetty-webapp</artifactId>
            <version>${jetty.version}</version>
            <scope>test</scope>
        </dependency>
        <dependency>
            <groupId>org.specs2</groupId>
            <artifactId>specs2-core_${scala.version}</artifactId>
            <version>4.3.4</version>
            <scope>test</scope>
        </dependency>
        <dependency>
            <groupId>org.mortbay.jetty</groupId>
            <artifactId>jetty</artifactId>
            <version>6.1.26</version>
            <scope>test</scope>
        </dependency>
        <!-- for LiftConsole -->
        <dependency>
            <groupId>org.scala-lang</groupId>
            <artifactId>scala-compiler</artifactId>
            <version>${scala.compiler}</version>
            <scope>compile</scope>
        </dependency>
        <dependency>
          <groupId>org.scala-lang</groupId>
          <artifactId>scala-library</artifactId>
          <version>${scala.compiler}</version>
        </dependency>
        <dependency>
            <groupId>oauth.signpost</groupId>
            <artifactId>signpost-commonshttp4</artifactId>
            <version>2.1.1</version>
        </dependency>
        <dependency>
            <groupId>com.squareup.okhttp3</groupId>
            <artifactId>okhttp</artifactId>
            <version>4.9.1</version>
        </dependency>
        <dependency>
            <groupId>com.github.OpenBankProject</groupId>
            <artifactId>scala-macros</artifactId>
            <version>v1.0.0-alpha.3</version>
        </dependency>
        <dependency>
            <groupId>com.nimbusds</groupId>
            <artifactId>nimbus-jose-jwt</artifactId>
            <version>9.1</version>
        </dependency>
        <dependency>
            <groupId>org.bouncycastle</groupId>
            <artifactId>bcpkix-jdk15on</artifactId>
            <version>1.62</version>
        </dependency>
        <dependency>
            <groupId>com.github.cb372</groupId>
            <artifactId>scalacache-guava_${scala.version}</artifactId>
            <version>0.9.3</version>
        </dependency>
        <dependency>
            <groupId>com.github.cb372</groupId>
            <artifactId>scalacache-redis_${scala.version}</artifactId>
            <version>0.9.3</version>
        </dependency>
        <dependency>
            <groupId>com.twitter</groupId>
            <artifactId>chill-akka_${scala.version}</artifactId>
            <version>0.9.1</version>
        </dependency>
        <dependency>
            <groupId>com.twitter</groupId>
            <artifactId>chill-bijection_${scala.version}</artifactId>
            <version>0.9.1</version>
        </dependency>
        <!-- https://mvnrepository.com/artifact/org.scala-lang.modules/scala-collection-compat -->
        <dependency>
            <groupId>org.scala-lang.modules</groupId>
            <artifactId>scala-collection-compat_${scala.version}</artifactId>
            <version>2.11.0</version>
        </dependency>

    </dependencies>

    <build>
        <sourceDirectory>src/main/scala</sourceDirectory>
        <testSourceDirectory>src/test/scala</testSourceDirectory>
            <plugins>
                <plugin>
                    <groupId>org.apache.maven.plugins</groupId>
                    <artifactId>maven-surefire-plugin</artifactId>
                    <version>${scala.version}</version>
                      <configuration>
                        <skipTests>true</skipTests>
                      </configuration>
                  </plugin>
                <plugin>
                    <!-- enable the scalatest plugin -->
                    <groupId>org.scalatest</groupId>
                    <artifactId>scalatest-maven-plugin</artifactId>
                    <version>1.0</version>
                    <configuration>
                        <reportsDirectory>${project.build.directory}/surefire-reports</reportsDirectory>
                        <junitxml>.</junitxml>
                        <filereports>WDF TestSuite.txt</filereports>
                        <argLine>-Drun.mode=test</argLine>
                    </configuration>
                    <executions>
                        <execution>
                        <id>test</id>
                        <goals>
                            <goal>test</goal>
                        </goals>
                        </execution>
                    </executions>
                </plugin>
                <plugin>
                    <!-- add src/main/java to source dirs -->
                    <groupId>org.codehaus.mojo</groupId>
                    <artifactId>build-helper-maven-plugin</artifactId>
                    <version>1.10</version>
                    <executions>
                        <execution>
                            <phase>generate-sources</phase>
                            <goals>
                                <goal>add-source</goal>
                            </goals>
                            <configuration>
                                <sources>
                                    <source>src/main/java</source>
                                </sources>
                            </configuration>
                        </execution>
                    </executions>
                </plugin>
                <plugin>
                    <groupId>net.alchim31.maven</groupId>
                    <artifactId>scala-maven-plugin</artifactId>
                    <version>4.3.1</version>
                    <configuration>
                        <charset>${project.build.sourceEncoding}</charset>
                        <jvmArgs>
                            <jvmArg>-Xmx1024m</jvmArg>
                            <jvmArg>-DpackageLinkDefs=file://${project.build.directory}/packageLinkDefs.properties</jvmArg>
                        </jvmArgs>
                        <scalaCompatVersion>${scala.version}</scalaCompatVersion>
                        <scalaVersion>${scala.compiler}</scalaVersion>
                        <recompileMode>incremental</recompileMode>
                    </configuration>
                    <executions>
                        <execution>
                            <goals>
                                <goal>compile</goal>
                                <goal>testCompile</goal>
                            </goals>
                            <configuration>
                                <args>
                                    <arg>-dependencyfile</arg>
                                    <arg>${project.build.directory}/.scala_dependencies</arg>
                                    <arg>-deprecation</arg>
                                </args>
                            </configuration>
                        </execution>
                        <execution>
                            <id>scala-test-compile</id>
                            <phase>process-test-resources</phase>
                            <goals>
                                <goal>testCompile</goal>
                            </goals>
                        </execution>
                    </executions>
                </plugin>
                <plugin>
                    <groupId>org.apache.maven.plugins</groupId>
                    <artifactId>maven-war-plugin</artifactId>
                    <version>2.6</version>
                </plugin>
                <plugin>
                    <groupId>org.apache.maven.plugins</groupId>
                    <artifactId>maven-resources-plugin</artifactId>
                    <version>3.0.1</version>
                    <executions>
                        <execution>
                            <id>default-copy-resources</id>
                            <phase>process-resources</phase>
                            <goals>
                                <goal>copy-resources</goal>
                            </goals>
                            <configuration>
                                <overwrite>true</overwrite>
                                <outputDirectory>${project.build.directory}</outputDirectory>
                                <resources>
                                    <resource>
                                        <directory>${project.basedir}/src</directory>
                                        <includes>
                                            <include>packageLinkDefs.properties</include>
                                        </includes>
                                        <filtering>true</filtering>
                                    </resource>
                                </resources>
                            </configuration>
                        </execution>
                    </executions>
                </plugin>
                <plugin>
                    <groupId>org.mortbay.jetty</groupId>
                    <artifactId>maven-jetty-plugin</artifactId>
                    <version>6.1.25</version>
                    <configuration>
                        <contextPath>/</contextPath>
                        <scanIntervalSeconds>5</scanIntervalSeconds>
                    </configuration>
                </plugin>
                <!-- TODO introduce the plug-in https://blutorange.github.io/closure-compiler-maven-plugin/
                <plugin>
                    <groupId>net.alchim31.maven</groupId>
                    <artifactId>yuicompressor-maven-plugin</artifactId>
                    <version>1.5.1</version>
                    <executions>
                        <execution>
                            <goals>
                                <goal>compress</goal>
                            </goals>
                        </execution>
                    </executions>
                    <configuration>
                        <nosuffix>true</nosuffix>
                        <encoding>UTF-8</encoding>
                    </configuration>
                </plugin>
                -->
                <plugin>
                    <groupId>org.apache.maven.plugins</groupId>
                    <artifactId>maven-idea-plugin</artifactId>
                    <version>2.2.1</version>
                    <configuration>
                        <downloadSources>true</downloadSources>
                    </configuration>
                </plugin>
                <plugin>
                    <groupId>org.apache.maven.plugins</groupId>
                    <artifactId>maven-eclipse-plugin</artifactId>
                    <version>2.10</version>
                    <configuration>
                        <downloadSources>true</downloadSources>
                        <additionalProjectnatures>
                            <projectnature>ch.epfl.lamp.sdt.core.scalanature</projectnature>
                        </additionalProjectnatures>
                        <additionalBuildcommands>
                            <buildcommand>ch.epfl.lamp.sdt.core.scalabuilder</buildcommand>
                        </additionalBuildcommands>
                        <classpathContainers>
                            <classpathContainer>ch.epfl.lamp.sdt.launching.SCALA_CONTAINER</classpathContainer>
                            <classpathContainer>org.eclipse.jdt.launching.JRE_CONTAINER</classpathContainer>
                        </classpathContainers>
                    </configuration>
                </plugin>
                <plugin>
                    <groupId>pl.project13.maven</groupId>
                    <artifactId>git-commit-id-plugin</artifactId>
                    <version>4.9.10</version>
                    <executions>
                        <execution>
                            <goals>
                                <goal>revision</goal>
                            </goals>
                        </execution>
                    </executions>
                    <configuration>
                        <dotGitDirectory>${project.basedir}/.git</dotGitDirectory>
                        <generateGitPropertiesFile>true</generateGitPropertiesFile>
                        <generateGitPropertiesFilename>src/main/resources/git.properties</generateGitPropertiesFilename>
                        <failOnNoGitDirectory>false</failOnNoGitDirectory>
                    </configuration>
                </plugin>
            </plugins>
    </build>
    <reporting>
        <plugins>
            <plugin>
                <groupId>net.alchim31.maven</groupId>
                <artifactId>scala-maven-plugin</artifactId>
            </plugin>
        </plugins>
    </reporting>
</project>
