<?xml version="1.0" encoding="UTF-8"?>
<!--
  ~ File created on Feb 19, 2019
  ~
  ~ Copyright (c) 2019 Carl Harris, Jr
  ~ and others as noted
  ~
  ~ 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">
  <parent>
    <groupId>org.soulwing.jwt</groupId>
    <artifactId>wildfly-jwt-extension</artifactId>
    <version>1.1.0</version>
  </parent>
  <modelVersion>4.0.0</modelVersion>

  <artifactId>jwt-provider</artifactId>
  <packaging>pom</packaging>
  <name>Wildfly JWT Provider Library</name>

  <properties>
    <version.org.jose4j>0.6.5</version.org.jose4j>
    <module.name>org.soulwing.jwt.provider</module.name>
    <module.slot>main</module.slot>
    <module.path>org/soulwing/jwt/provider/${module.slot}</module.path>
    <module.directory>${project.build.directory}/modules/${module.path}</module.directory>
  </properties>

  <build>
    <plugins>
      <plugin>
        <artifactId>maven-resources-plugin</artifactId>
        <executions>
          <execution>
            <id>copy-module-descriptor</id>
            <goals>
              <goal>copy-resources</goal>
            </goals>
            <phase>process-resources</phase>
            <configuration>
              <outputDirectory>${module.directory}</outputDirectory>
              <resources>
                <resource>
                  <directory>src/module</directory>
                  <filtering>true</filtering>
                  <includes>
                    <include>**/*.xml</include>
                  </includes>
                </resource>
                <resource>
                  <directory>src/module</directory>
                  <filtering>false</filtering>
                  <excludes>
                    <exclude>**/*.xml</exclude>
                  </excludes>
                </resource>
              </resources>
            </configuration>
          </execution>
        </executions>
      </plugin>
      <plugin>
        <artifactId>maven-dependency-plugin</artifactId>
        <executions>
          <execution>
            <id>copy-module-dependencies</id>
            <goals>
              <goal>copy-dependencies</goal>
            </goals>
            <phase>prepare-package</phase>
            <configuration>
              <outputDirectory>${module.directory}</outputDirectory>
              <includeArtifactIds>jwt-api,jose4j</includeArtifactIds>
            </configuration>
          </execution>
        </executions>
      </plugin>
    </plugins>
  </build>
  <dependencies>
    <dependency>
      <groupId>org.soulwing.jwt</groupId>
      <artifactId>jwt-api</artifactId>
    </dependency>
    <dependency>
      <groupId>org.bitbucket.b_c</groupId>
      <artifactId>jose4j</artifactId>
      <version>${version.org.jose4j}</version>
    </dependency>
  </dependencies>

</project>