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

    <parent>
        <groupId>com.github.subchen</groupId>
        <artifactId>jetbrick-template-parent</artifactId>
        <version>2.2.0</version>
    </parent>

    <modelVersion>4.0.0</modelVersion>
    <artifactId>jetbrick-template</artifactId>
    <packaging>jar</packaging>

    <name>jetbrick-template</name>
    <description>Next generation template engine for Java</description>

    <properties>
        <antlr4.version>4.10.1</antlr4.version>
        <antlr4.listener>false</antlr4.listener>
        <antlr4.visitor>true</antlr4.visitor>
    </properties>

    <build>
        <plugins>
            <plugin>
                <groupId>org.antlr</groupId>
                <artifactId>antlr4-maven-plugin</artifactId>
                <version>${antlr4.version}</version>
                <executions>
                    <execution>
                        <goals>
                            <goal>antlr4</goal>
                        </goals>
                    </execution>
                </executions>
                <configuration>
                    <sourceDirectory>${basedir}/src/main/antlr4</sourceDirectory>
                    <outputDirectory>${basedir}/target/generated-sources/antlr4</outputDirectory>
                    <visitor>true</visitor>
                </configuration>
            </plugin>

            <!--
            <plugin>
                <groupId>org.apache.maven.plugins/groupId>
                <artifactId>maven-shade-plugin</artifactId>
                <version>3.2.4</version>
                <executions>
                    <execution>
                        <phase>package</phase>
                        <goals>
                            <goal>shade</goal>
                        </goals>
                        <configuration>
                            <minimizeJar>true</minimizeJar>
                            <artifactSet>
                                <includes>
                                    <include>org.antlr:antlr4-runtime</include>
                                </includes>
                            </artifactSet>
                            <relocations>
                                <relocation>
                                    <pattern>org.antlr.v4.runtime</pattern>
                                    <shadedPattern>com.github.subchen.jetbrick.template.internal.antlr</shadedPattern>
                                </relocation>
                            </relocations>
                        </configuration>
                    </execution>
                </executions>
            <plugin>
            -->

            <plugin>
                <groupId>org.apache.maven.plugins</groupId>
                <artifactId>maven-surefire-plugin</artifactId>
                <version>3.2.5</version>
                <configuration>
                    <argLine>--add-opens java.base/java.lang=ALL-UNNAMED</argLine>
                </configuration>
            </plugin>
        </plugins>
    </build>

    <dependencies>
        <dependency>
            <groupId>${project.groupId}</groupId>
            <artifactId>jetbrick-commons</artifactId>
            <version>2.1.9</version>
        </dependency>
        <dependency>
            <groupId>org.antlr</groupId>
            <artifactId>antlr4-runtime</artifactId>
            <version>${antlr4.version}</version>
        </dependency>
        <dependency>
            <groupId>org.slf4j</groupId>
            <artifactId>slf4j-api</artifactId>
            <version>${slf4j.version}</version>
        </dependency>
        <dependency>
            <groupId>junit</groupId>
            <artifactId>junit</artifactId>
            <version>${junit.version}</version>
            <scope>test</scope>
        </dependency>
        <dependency>
            <groupId>org.slf4j</groupId>
            <artifactId>slf4j-simple</artifactId>
            <version>${slf4j.version}</version>
            <scope>test</scope>
        </dependency>
    </dependencies>

</project>
