<?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>
    <groupId>com.rapiddweller</groupId>
    <artifactId>rd-lib-script</artifactId>
    <version>1.1.4-jdk-11</version>
    <packaging>jar</packaging>
    <name>rapiddweller Script</name>
    <description>'rapiddweller Script' is an open source software library for resolving Java-like script expressions,
        forked from Databene Scripts written by Volker Bergmann.
    </description>
    <url>https://www.rapiddweller.com/opensource/rd-lib-script</url>
    <inceptionYear>2011</inceptionYear>

    <properties>
        <maven.compiler.source>11</maven.compiler.source>
        <maven.compiler.target>11</maven.compiler.target>
        <_rd_common_version>2.0.0-jdk-11</_rd_common_version>
        <buildnumber-maven-plugin.version>1.0</buildnumber-maven-plugin.version>
        <dependency_antlr-runtime.version>3.3</dependency_antlr-runtime.version>
        <dependency_junit.version>4.13.2</dependency_junit.version>
        <dependency_slf4j.version>1.7.32</dependency_slf4j.version>
        <dependency_log4j.version>2.17.0</dependency_log4j.version>
        <dependency_poi.version>5.0.0</dependency_poi.version>
        <plugin_jacoco-maven-plugin.version>0.8.6</plugin_jacoco-maven-plugin.version>
        <plugin_maven-assembly-plugin.version>3.3.0</plugin_maven-assembly-plugin.version>
        <plugin_maven-compiler-plugin.version>3.8.1</plugin_maven-compiler-plugin.version>
        <plugin_maven-gpg-plugin.version>1.6</plugin_maven-gpg-plugin.version>
        <plugin_maven-jar-plugin.version>2.5</plugin_maven-jar-plugin.version>
        <plugin_maven-javadoc-plugin.version>3.2.0</plugin_maven-javadoc-plugin.version>
        <plugin_maven-project-info-reports-plugin.version>3.1.1</plugin_maven-project-info-reports-plugin.version>
        <plugin_maven-resources-plugin.version>2.6</plugin_maven-resources-plugin.version>
        <plugin_maven-site-plugin.version>3.9.1</plugin_maven-site-plugin.version>
        <plugin_maven-source-plugin.version>3.2.1</plugin_maven-source-plugin.version>
        <plugin_maven-surefire-plugin.version>3.0.0-M5</plugin_maven-surefire-plugin.version>
        <plugin_maven-surefire-report-plugin.version>3.0.0-M5</plugin_maven-surefire-report-plugin.version>
        <plugin_nexus-staging-maven-plugin.version>1.6.8</plugin_nexus-staging-maven-plugin.version>
        <plugin_surefire-api.version>3.0.0-M5</plugin_surefire-api.version>
        <plugin_surefire-junit4.version>3.0.0-M5</plugin_surefire-junit4.version>
        <plugin_versions-maven-plugin.version>2.8.1</plugin_versions-maven-plugin.version>
        <project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
    </properties>

    <licenses>
        <license>
            <name>Apache License 2.0</name>
            <url>http://www.apache.org/licenses/LICENSE-2.0</url>
        </license>
    </licenses>

    <organization>
        <name>rapiddweller GmbH</name>
        <url>https://www.rapiddweller.com</url>
    </organization>

    <developers>
        <developer>
            <id>volker.bergmann</id>
            <name>Volker Bergmann</name>
            <email>volker.bergmann@databene.org</email>
            <roles>
                <role>project founder</role>
                <role>architect</role>
                <role>developer</role>
            </roles>
            <timezone>UTC+01:00</timezone>
        </developer>
        <developer>
            <id>alexander.kell</id>
            <name>Alexander Kell</name>
            <email>alexander.kell@rapiddweller.com</email>
            <organization>rapiddweller GmbH</organization>
            <organizationUrl>https://www.rapiddweller.com</organizationUrl>
            <roles>
                <role>architect</role>
                <role>developer</role>
            </roles>
            <timezone>UTC+01:00</timezone>
        </developer>
        <developer>
            <id>peter.brinkhoff</id>
            <name>Peter Brinkhoff</name>
            <email>peter.brinkhoff@rapiddweller.com</email>
            <organization>rapiddweller GmbH</organization>
            <organizationUrl>https://www.rapiddweller.com</organizationUrl>
            <roles>
                <role>architect</role>
                <role>developer</role>
            </roles>
            <timezone>UTC+07:00</timezone>
        </developer>
    </developers>

    <dependencies>
        <!-- rapiddweller dependencies -->
        <dependency>
            <groupId>com.rapiddweller</groupId>
            <artifactId>rd-lib-common</artifactId>
            <version>${_rd_common_version}</version>
        </dependency>
        <!--  ANTLR (ANother Tool for Language Recognition) is a powerful parser generator for reading, processing,
         executing, or translating structured text or binary files. It's widely used to build languages, tools, and
          frameworks. From a grammar, ANTLR generates a parser that can build and walk parse trees. -->
        <dependency>
            <groupId>org.antlr</groupId>
            <artifactId>antlr</artifactId>
            <version>${dependency_antlr-runtime.version}</version>
        </dependency>
        <!-- Test dependencies -->
        <dependency>
            <groupId>junit</groupId>
            <artifactId>junit</artifactId>
            <version>${dependency_junit.version}</version>
            <scope>test</scope>
        </dependency>
        <!-- logging -->
        <dependency>
            <groupId>org.slf4j</groupId>
            <artifactId>slf4j-api</artifactId>
            <version>${dependency_slf4j.version}</version>
        </dependency>
        <dependency>
            <groupId>org.apache.logging.log4j</groupId>
            <artifactId>log4j-slf4j-impl</artifactId>
            <version>${dependency_log4j.version}</version>
            <scope>test</scope>
        </dependency>
        <dependency>
            <groupId>org.apache.logging.log4j</groupId>
            <artifactId>log4j-api</artifactId>
            <version>${dependency_log4j.version}</version>
            <scope>test</scope>
        </dependency>
        <dependency>
            <groupId>org.apache.logging.log4j</groupId>
            <artifactId>log4j-core</artifactId>
            <version>${dependency_log4j.version}</version>
            <scope>test</scope>
        </dependency>
        <!-- Excel -->
        <dependency>
            <groupId>org.apache.poi</groupId>
            <artifactId>poi-ooxml-full</artifactId>
            <version>${dependency_poi.version}</version>
        </dependency>
        <dependency>
            <groupId>org.apache.poi</groupId>
            <artifactId>poi</artifactId>
            <version>${dependency_poi.version}</version>
        </dependency>
    </dependencies>

    <build>
        <resources>
            <resource>
                <filtering>false</filtering>
                <directory>${basedir}/src/main/resources</directory>
                <includes>
                    <include>**/*.xml</include>
                    <include>**/*.xsl</include>
                    <include>**/*.properties</include>
                    <include>**/*.dtd</include>
                    <include>**/*.csv</include>
                    <include>**/*.txt</include>
                </includes>
                <excludes>
                    <exclude>log4j.xml</exclude>
                    <exclude>**/version.properties</exclude>
                </excludes>
            </resource>
            <resource>
                <filtering>true</filtering>
                <directory>${basedir}/src/main/resources</directory>
                <includes>
                    <include>**/version.properties</include>
                </includes>
            </resource>
            <resource>
                <filtering>false</filtering>
                <directory>${basedir}/src/demo/resources</directory>
                <includes>
                    <include>**/*</include>
                </includes>
            </resource>
            <resource>
                <filtering>false</filtering>
                <directory>${basedir}</directory>
                <includes>
                    <include>license.txt</include>
                </includes>
            </resource>
        </resources>
        <testResources>
            <testResource>
                <filtering>false</filtering>
                <directory>${basedir}/src/test/resources</directory>
                <includes>
                    <include>**/*</include>
                </includes>
            </testResource>
        </testResources>
        <plugins>
            <plugin>
                <artifactId>maven-assembly-plugin</artifactId>
                <version>${plugin_maven-assembly-plugin.version}</version>
                <configuration>
                    <descriptors>
                        <descriptor>src/main/assembly/dist-assembly.xml</descriptor>
                    </descriptors>
                    <tarLongFileMode>gnu</tarLongFileMode>
                </configuration>
            </plugin>
            <plugin>
                <artifactId>maven-jar-plugin</artifactId>
                <version>${plugin_maven-jar-plugin.version}</version>
                <configuration>
                    <archive>
                        <manifest>
                            <mainClass>com.rapiddweller.main.Benerator</mainClass>
                            <addClasspath>true</addClasspath>
                            <classpathPrefix>lib/</classpathPrefix>
                        </manifest>
                    </archive>
                </configuration>
            </plugin>
            <plugin>
                <artifactId>maven-resources-plugin</artifactId>
                <version>${plugin_maven-resources-plugin.version}</version>
            </plugin>
            <plugin>
                <groupId>org.apache.maven.plugins</groupId>
                <artifactId>maven-compiler-plugin</artifactId>
                <version>${plugin_maven-compiler-plugin.version}</version>
                <configuration>
                    <source>${maven.compiler.source}</source>
                    <target>${maven.compiler.target}</target>
                </configuration>
            </plugin>
            <plugin>
                <groupId>org.apache.maven.plugins</groupId>
                <artifactId>maven-javadoc-plugin</artifactId>
                <version>${plugin_maven-javadoc-plugin.version}</version>
                <configuration>
                    <doclint>none</doclint>
                    <source>${maven.compiler.source}</source>
                    <detectJavaApiLink>false</detectJavaApiLink>
                </configuration>
                <executions>
                    <execution>
                        <id>attach-javadocs</id>
                        <goals>
                            <goal>jar</goal>
                        </goals>
                    </execution>
                </executions>
            </plugin>
            <plugin>
                <groupId>org.apache.maven.plugins</groupId>
                <artifactId>maven-site-plugin</artifactId>
                <version>${plugin_maven-site-plugin.version}</version>
                <executions>
                    <execution>
                        <id>create-site</id>
                        <goals>
                            <goal>site</goal>
                        </goals>
                    </execution>
                </executions>
            </plugin>
            <plugin>
                <groupId>org.apache.maven.plugins</groupId>
                <artifactId>maven-source-plugin</artifactId>
                <version>${plugin_maven-source-plugin.version}</version>
                <executions>
                    <execution>
                        <id>attach-sources</id>
                        <goals>
                            <goal>jar-no-fork</goal>
                        </goals>
                    </execution>
                </executions>
            </plugin>
            <plugin>
                <groupId>org.apache.maven.plugins</groupId>
                <artifactId>maven-surefire-plugin</artifactId>
                <version>${plugin_maven-surefire-plugin.version}</version>
                <configuration>
                    <useSystemClassLoader>false</useSystemClassLoader>
                </configuration>
                <dependencies>
                    <dependency>
                        <groupId>org.apache.maven.surefire</groupId>
                        <artifactId>surefire-junit4</artifactId>
                        <version>${plugin_surefire-junit4.version}</version>
                    </dependency>
                    <dependency>
                        <groupId>org.apache.maven.surefire</groupId>
                        <artifactId>surefire-api</artifactId>
                        <version>${plugin_surefire-api.version}</version>
                    </dependency>
                </dependencies>
            </plugin>
            <plugin>
                <groupId>org.codehaus.mojo</groupId>
                <artifactId>buildnumber-maven-plugin</artifactId>
                <version>${buildnumber-maven-plugin.version}</version>
                <executions>
                    <execution>
                        <phase>validate</phase>
                        <goals>
                            <goal>create</goal>
                        </goals>
                    </execution>
                </executions>
                <configuration>
                    <doCheck>false</doCheck>
                    <doUpdate>false</doUpdate>
                    <format>{0,number,#####}</format>
                    <items>
                        <item>buildNumber0</item>
                    </items>
                    <revisionOnScmFailure>x</revisionOnScmFailure>
                </configuration>
            </plugin>
            <plugin>
                <groupId>org.codehaus.mojo</groupId>
                <artifactId>versions-maven-plugin</artifactId>
                <version>${plugin_versions-maven-plugin.version}</version>
            </plugin>
            <plugin>
                <groupId>org.jacoco</groupId>
                <artifactId>jacoco-maven-plugin</artifactId>
                <version>${plugin_jacoco-maven-plugin.version}</version>
                <configuration>
                    <excludes>
                        <exclude>com/rapiddweller/common/anno/**/*</exclude>
                        <exclude>com/rapiddweller/common/**/*Exception.*</exclude>
                        <exclude>com/rapiddweller/benerator/main/Benerator.class</exclude>
                    </excludes>
                </configuration>
                <executions>
                    <execution>
                        <goals>
                            <goal>prepare-agent</goal>
                        </goals>
                    </execution>
                    <execution>
                        <id>report</id>
                        <phase>prepare-package</phase>
                        <goals>
                            <goal>report</goal>
                        </goals>
                    </execution>
                </executions>
            </plugin>
        </plugins>
    </build>

    <reporting>
        <plugins>
            <plugin>
                <groupId>org.apache.maven.plugins</groupId>
                <artifactId>maven-surefire-report-plugin</artifactId>
                <version>${plugin_maven-surefire-report-plugin.version}</version>
            </plugin>
            <plugin>
                <groupId>org.apache.maven.plugins</groupId>
                <artifactId>maven-javadoc-plugin</artifactId>
                <version>${plugin_maven-javadoc-plugin.version}</version>
                <configuration>
                    <doclint>none</doclint>
                    <source>${maven.compiler.source}</source>
                    <detectJavaApiLink>false</detectJavaApiLink>
                </configuration>
            </plugin>
            <plugin>
                <groupId>org.jacoco</groupId>
                <artifactId>jacoco-maven-plugin</artifactId>
                <reportSets>
                    <reportSet>
                        <reports>
                            <!-- select non-aggregate reports -->
                            <report>report</report>
                        </reports>
                    </reportSet>
                </reportSets>
            </plugin>
            <plugin>
                <groupId>org.apache.maven.plugins</groupId>
                <artifactId>maven-project-info-reports-plugin</artifactId>
                <version>${plugin_maven-project-info-reports-plugin.version}</version>
                <reportSets>
                    <reportSet>
                        <reports>
                            <report>index</report>
                            <report>dependencies</report>
                            <report>team</report>
                            <report>licenses</report>
                            <report>plugins</report>
                        </reports>
                    </reportSet>
                </reportSets>
            </plugin>
        </plugins>
    </reporting>

    <profiles>
        <profile>
            <id>release</id>
            <build>
                <plugins>
                    <plugin>
                        <groupId>org.apache.maven.plugins</groupId>
                        <artifactId>maven-source-plugin</artifactId>
                        <version>${plugin_maven-source-plugin.version}</version>
                        <executions>
                            <execution>
                                <id>attach-sources</id>
                                <goals>
                                    <goal>jar-no-fork</goal>
                                </goals>
                            </execution>
                        </executions>
                    </plugin>
                    <plugin>
                        <groupId>org.apache.maven.plugins</groupId>
                        <artifactId>maven-javadoc-plugin</artifactId>
                        <version>${plugin_maven-javadoc-plugin.version}</version>
                        <executions>
                            <execution>
                                <id>attach-javadocs</id>
                                <goals>
                                    <goal>jar</goal>
                                </goals>
                            </execution>
                        </executions>
                    </plugin>
                    <plugin>
                        <groupId>org.apache.maven.plugins</groupId>
                        <artifactId>maven-gpg-plugin</artifactId>
                        <version>${plugin_maven-gpg-plugin.version}</version>
                        <executions>
                            <execution>
                                <id>sign-artifacts</id>
                                <phase>verify</phase>
                                <goals>
                                    <goal>sign</goal>
                                </goals>
                                <configuration>
                                    <gpgArguments>
                                        <arg>--pinentry-mode</arg>
                                        <arg>loopback</arg>
                                    </gpgArguments>
                                </configuration>
                            </execution>
                        </executions>
                    </plugin>
                    <plugin>
                        <groupId>org.sonatype.plugins</groupId>
                        <artifactId>nexus-staging-maven-plugin</artifactId>
                        <version>${plugin_nexus-staging-maven-plugin.version}</version>
                        <extensions>true</extensions>
                        <configuration>
                            <serverId>ossrh</serverId>
                            <nexusUrl>https://oss.sonatype.org/</nexusUrl>
                            <autoReleaseAfterClose>false</autoReleaseAfterClose>
                        </configuration>
                    </plugin>
                </plugins>
            </build>
            <distributionManagement>
                <snapshotRepository>
                    <id>ossrh</id>
                    <url>https://oss.sonatype.org/content/repositories/snapshots</url>
                </snapshotRepository>
            </distributionManagement>
        </profile>
    </profiles>

    <repositories>
        <repository>
            <id>central</id>
            <url>https://repo1.maven.org/maven2</url>
            <releases>
                <enabled>true</enabled>
            </releases>
            <snapshots>
                <enabled>false</enabled>
            </snapshots>
        </repository>
        <repository>
            <id>snapshots-repo</id>
            <url>https://oss.sonatype.org/content/repositories/snapshots</url>
            <releases>
                <enabled>false</enabled>
            </releases>
            <snapshots>
                <enabled>true</enabled>
            </snapshots>
        </repository>
    </repositories>

    <scm>
        <url>https://github.com/rapiddweller/rd-lib-script</url>
        <connection>scm:git:git://github.com/rapiddweller/rd-lib-script.git</connection>
        <developerConnection>scm:git:git://github.com/rapiddweller/rd-lib-script.git</developerConnection>
    </scm>
</project>
