<?xml version="1.0" encoding="UTF-8"?>
<assembly
    xmlns="http://maven.apache.org/plugins/maven-assembly-plugin/assembly/1.1.2"
    xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
    xsi:schemaLocation="http://maven.apache.org/plugins/maven-assembly-plugin/assembly/1.1.2 http://maven.apache.org/xsd/assembly-1.1.2.xsd">

  <id>dist</id>
  <formats>
    <format>zip</format>
    <format>dir</format>
  </formats>

  <includeBaseDirectory>false</includeBaseDirectory>
  <fileSets>
    <fileSet>
      <directory>${project.build.directory}/wildfly-${version.org.wildfly}</directory>
      <outputDirectory>.</outputDirectory>
      <excludes>
        <exclude>README.txt</exclude>
      </excludes>
    </fileSet>
    <fileSet>
      <directory>${project.basedir}</directory>
      <includes>
        <include>README.txt</include>
      </includes>
      <outputDirectory>.</outputDirectory>
    </fileSet>
  </fileSets>

  <dependencySets>
    <dependencySet>
      <includes>
        <include>${project.groupId}:${project.artifactId}</include>
      </includes>
      <outputDirectory>standalone/deployments</outputDirectory>
      <outputFileNameMapping>${artifact.artifactId}.${artifact.extension}</outputFileNameMapping>
      <useProjectArtifact>true</useProjectArtifact>
    </dependencySet>
  </dependencySets>

</assembly>