<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>
    <parent>
        <groupId>info.archinnov</groupId>
        <artifactId>achilles</artifactId>
        <version>2.0.9</version>
    </parent>
    <artifactId>achilles-documentation</artifactId>
    <name>Achilles Documentation</name>
    <packaging>pom</packaging>
    <description>Achilles Documentation Module</description>
    <profiles>
        <profile>
            <id>build-documentation</id>
            <activation>
                <activeByDefault>false</activeByDefault>
                <property>
                    <name>performRelease</name>
                    <value>true</value>
                </property>
            </activation>
            <build>
                <plugins>
                    <plugin>
                        <artifactId>exec-maven-plugin</artifactId>
                        <groupId>org.codehaus.mojo</groupId>
                        <executions>
                            <execution>
                                <id>Generate Documentation</id>
                                <phase>package</phase>
                                <goals>
                                    <goal>exec</goal>
                                </goals>
                                <configuration>
                                    <executable>${basedir}/scripts/generate-doc.sh</executable>
                                    <arguments>
                                        <argument>${basedir}</argument>
                                    </arguments>
                                </configuration>
                            </execution>
                        </executions>
                    </plugin>
                    <plugin>
                        <groupId>org.apache.maven.plugins</groupId>
                        <artifactId>maven-assembly-plugin</artifactId>
                        <configuration>
                            <descriptor>src/assembly/assembly.xml</descriptor>
                            <finalName>achilles-${project.version}-documentation</finalName>
                        </configuration>
                        <executions>
                            <execution>
                                <phase>package</phase>
                                <goals>
                                    <goal>single</goal>
                                </goals>
                            </execution>
                        </executions>
                    </plugin>
                </plugins>
            </build>
        </profile>
    </profiles>
</project>
