<?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/maven-v4_0_0.xsd">
    <modelVersion>4.0.0</modelVersion>

    <parent>
        <groupId>be.orbinson.aem</groupId>
        <artifactId>aem-groovy-console</artifactId>
        <version>19.0.2</version>
    </parent>

    <artifactId>aem-groovy-console-ui.apps</artifactId>
    <packaging>content-package</packaging>
    <name>AEM Groovy Console - UI apps</name>

    <build>
        <plugins>
            <plugin>
                <groupId>org.apache.jackrabbit</groupId>
                <artifactId>filevault-package-maven-plugin</artifactId>
                <extensions>true</extensions>
                <configuration>
                    <group>${package.group}</group>
                    <name>aem-groovy-console-ui.apps</name>
                    <packageType>application</packageType>
                    <accessControlHandling>merge</accessControlHandling>
                    <properties>
                        <cloudManagerTarget>none</cloudManagerTarget>
                    </properties>
                    <repositoryStructurePackages>
                        <repositoryStructurePackage>
                            <groupId>be.orbinson.aem</groupId>
                            <artifactId>aem-groovy-console-ui.apps.structure</artifactId>
                        </repositoryStructurePackage>
                    </repositoryStructurePackages>
                    <validatorsSettings>
                        <jackrabbit-nodetypes>
                            <isDisabled>true</isDisabled>
                        </jackrabbit-nodetypes>
                    </validatorsSettings>
                </configuration>
            </plugin>
            <plugin>
                <groupId>io.wcm.maven.plugins</groupId>
                <artifactId>wcmio-content-package-maven-plugin</artifactId>
                <extensions>true</extensions>
            </plugin>
        </plugins>
    </build>

    <dependencies>
        <dependency>
            <groupId>be.orbinson.aem</groupId>
            <artifactId>aem-groovy-console-bundle</artifactId>
            <version>${project.version}</version>
        </dependency>
        <dependency>
            <groupId>be.orbinson.aem</groupId>
            <artifactId>aem-groovy-console-ui.apps.structure</artifactId>
            <version>${project.version}</version>
            <type>zip</type>
        </dependency>

        <dependency>
            <groupId>com.adobe.aem</groupId>
            <artifactId>uber-jar</artifactId>
        </dependency>
    </dependencies>

    <profiles>
        <profile>
            <id>auto-deploy</id>
            <build>
                <plugins>
                    <plugin>
                        <groupId>io.wcm.maven.plugins</groupId>
                        <artifactId>wcmio-content-package-maven-plugin</artifactId>
                        <executions>
                            <execution>
                                <id>install-package</id>
                                <goals>
                                    <goal>install</goal>
                                </goals>
                                <configuration>
                                    <serviceURL>http://${aem.host}:${aem.port}/${service.path}</serviceURL>
                                </configuration>
                            </execution>
                        </executions>
                    </plugin>
                </plugins>
            </build>
        </profile>
    </profiles>

</project>
