<?xml version="1.0"?>
<project
    xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd"
    xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">
  <modelVersion>4.0.0</modelVersion>

  <groupId>io.jooby</groupId>
  <artifactId>starters</artifactId>
  <packaging>pom</packaging>
  <version>1.0.0</version>

  <modules>
    <module>guice-starter</module>
    <module>graphql-starter</module>
    <module>jdbi-starter</module>
    <module>ebean-starter</module>
    <module>hibernate-starter</module>
    <module>pac4j-form-starter</module>
    <module>pac4j-starter</module>
    <module>quartz-starter</module>
    <module>spring-starter</module>
  </modules>

  <profiles>
    <profile>
      <id>release</id>
      <activation>
        <property>
          <name>JOOBY_VERSION</name>
        </property>
      </activation>
      <build>
        <plugins>
          <plugin>
            <artifactId>maven-antrun-plugin</artifactId>
            <version>1.8</version>
            <executions>
              <execution>
                <phase>initialize</phase>
                <configuration>
                  <target>
                    <replaceregexp match="&lt;jooby.version&gt;.*&lt;/jooby.version&gt;"
                                   replace="&lt;jooby.version&gt;${JOOBY_VERSION}&lt;/jooby.version&gt;">
                      <fileset dir="${basedir}" includes="*-starter/pom.xml"/>
                    </replaceregexp>
                  </target>
                </configuration>
                <goals>
                  <goal>run</goal>
                </goals>
                <inherited>false</inherited>
              </execution>
            </executions>
          </plugin>
        </plugins>
      </build>
    </profile>
  </profiles>

</project>
