<?xml version="1.0" encoding="UTF-8" ?>
<!--
  ~ Copyright 2017 DV Bern AG
  ~
  ~ Licensed under the Apache License, Version 2.0 (the "License");
  ~ you may not use this file except in compliance with the License.
  ~ You may obtain a copy of the License at
  ~
  ~ http://www.apache.org/licenses/LICENSE-2.0
  ~
  ~ Unless required by applicable law or agreed to in writing, software
  ~ distributed under the License is distributed on an "AS IS" BASIS,
  ~ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
  ~ limitations under the License.
  -->

<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 https://maven.apache.org/maven-v4_0_0.xsd">
    <modelVersion>4.0.0</modelVersion>

    <groupId>ch.dvbern.oss.maven</groupId>
    <artifactId>parent</artifactId>
    <version>5.0.0</version>
    <packaging>pom</packaging>

    <name>Maven OSS Parent POM der DV Bern AG</name>
    <description>Maven Einstellung, die allgemeine Gueltigkeit fuer die Open-Source-Projekte der DV Bern AG haben</description>
    <url>https://github.com/dvbern/oss-maven-parent-pom</url>

    <organization>
        <name>DV Bern AG</name>
        <url>https://www.dvbern.ch/</url>
    </organization>

    <developers>
        <developer>
            <name>Christoph Linder</name>
            <email>christoph.linder@dvbern.ch</email>
            <organization>DV Bern AG</organization>
            <roles>
                <role>Developer</role>
                <role>Architect</role>
            </roles>
        </developer>
    </developers>

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

    <scm>
        <url>https://github.com/dvbern/oss-maven-parent-pom.git</url>
        <connection>scm:git:https://github.com/dvbern/oss-maven-parent-pom.git</connection>
        <developerConnection>scm:git:https://github.com/dvbern/oss-maven-parent-pom.git</developerConnection>
    </scm>

    <modules>
        <module>code-conventions</module>
    </modules>

    <profiles>
        <profile>
            <id>development-mode</id>
            <properties>
                <skipTests>true</skipTests>
                <skip-code-validation>true</skip-code-validation>
                <skip-javadoc>true</skip-javadoc>
            </properties>
        </profile>
        <profile>
            <id>maven-central</id>
            <properties>
                <skip-javadoc />
            </properties>
            <build>
                <plugins>

                    <!-- maven-gpg-plugin -->
                    <plugin>
                        <groupId>org.apache.maven.plugins</groupId>
                        <artifactId>maven-gpg-plugin</artifactId>
                        <version>${maven-gpg-plugin.version}</version>
                        <executions>
                            <execution>
                                <id>sign-artifacts</id>
                                <phase>verify</phase>
                                <goals>
                                    <goal>sign</goal>
                                </goals>
                            </execution>
                            <!-- configuration: see jenkins ~/.gnupg & ~/.m2/settings.xml -->
                        </executions>
                    </plugin>

                    <!-- nexus-staging-maven-plugin -->
                    <plugin>
                        <groupId>org.sonatype.plugins</groupId>
                        <artifactId>nexus-staging-maven-plugin</artifactId>
                        <version>${nexus-staging-maven-plugin.version}</version>
                        <extensions>true</extensions>
                        <configuration>
                            <serverId>ossrh</serverId>
                            <nexusUrl>https://oss.sonatype.org/</nexusUrl>
                            <autoReleaseAfterClose>true</autoReleaseAfterClose>
                        </configuration>
                        <executions>
                            <execution>
                                <id>deploy</id>
                            </execution>
                        </executions>
                        <!-- configuration: see jenkins ~/.m2/settings.xml -->
                    </plugin>
                </plugins>
            </build>
        </profile>
    </profiles>

    <build>

        <!--
			  The Plugin Management Section defines configuration for Plugins that
			  are automatically applied on sub-poms IF the plugins are used there.

			  Any	sub-pom may define the usage of plugins listed here by simply
			  defining the artifactId and groupId (if the plugin is not bound to
			  the lifecycle anyway):

			  <build>
				  <plugins>
					  <plugin>
						  <groupId>just-an-example-plugin-group</plugin>
						  <artifactId>just-an-example-plugin</artifactId>
					  </plugin>
				  </plugins>
			  </build>

			  For plugins that are bound to the default lifecycle by
			  default, however, this is not necessary.
		-->
        <pluginManagement>
            <plugins>

                <plugin>
                    <groupId>org.codehaus.mojo</groupId>
                    <artifactId>versions-maven-plugin</artifactId>
                    <version>${versions-maven-plugin.version}</version>
                    <inherited>false</inherited>
                    <dependencies>
                        <dependency>
                            <groupId>ch.dvbern.oss.maven</groupId>
                            <artifactId>code-conventions</artifactId>
                            <version>${code-conventions.release.version}</version>
                        </dependency>
                    </dependencies>
                    <configuration>
                        <!-- run with: mvn versions:display-dependency-updates-->
                        <outputFile>${project.build.directory}/outdated-dependencies.txt</outputFile>
                        <rulesUri>classpath:///rules/versions/mvn-versions-rules.xml</rulesUri>
                    </configuration>
                </plugin>

                <!-- maven-jar-plugin: Defines custom manifest entries when building JARs -->
                <plugin>
                    <groupId>org.apache.maven.plugins</groupId>
                    <artifactId>maven-jar-plugin</artifactId>
                    <version>${maven-jar-plugin.version}</version>
                    <configuration>
                        <archive>
                            <manifest>
                                <addDefaultSpecificationEntries>true</addDefaultSpecificationEntries>
                                <addDefaultImplementationEntries>true</addDefaultImplementationEntries>
                            </manifest>
                            <manifestEntries>
                                <Build-Timestamp>${maven.build.timestamp}</Build-Timestamp>
                                <OS-Name>${os.name}</OS-Name>
                                <Artifact-Name>${project.name}</Artifact-Name>
                                <Version>${project.version}</Version>
                                <Artifact-Group>${project.groupId}</Artifact-Group>
                                <Description>${project.description}</Description>
                            </manifestEntries>
                        </archive>
                    </configuration>
                </plugin>

                <!-- maven-ejb-plugin: Defines custom manifest entries when building EJB-JARs -->
                <plugin>
                    <groupId>org.apache.maven.plugins</groupId>
                    <artifactId>maven-ejb-plugin</artifactId>
                    <version>${maven-ejb-plugin.version}</version>
                    <configuration>
                        <archive>
                            <manifestEntries>
                                <Build-Timestamp>${maven.build.timestamp}</Build-Timestamp>
                                <OS-Name>${os.name}</OS-Name>
                                <Artifact-Name>${project.name}</Artifact-Name>
                                <Version>${project.version}</Version>
                                <Artifact-Group>${project.groupId}</Artifact-Group>
                                <Description>${project.description}</Description>
                            </manifestEntries>
                        </archive>
                    </configuration>
                </plugin>

                <!-- maven-ear-plugin: Defines custom manifest entries when building EARs -->
                <plugin>
                    <groupId>org.apache.maven.plugins</groupId>
                    <artifactId>maven-ear-plugin</artifactId>
                    <version>${maven-ear-plugin.version}</version>
                    <configuration>
                        <archive>
                            <manifestEntries>
                                <Build-Timestamp>${maven.build.timestamp}</Build-Timestamp>
                                <OS-Name>${os.name}</OS-Name>
                                <Artifact-Name>${project.name}</Artifact-Name>
                                <Version>${project.version}</Version>
                                <Artifact-Group>${project.groupId}</Artifact-Group>
                                <Description>${project.description}</Description>
                            </manifestEntries>
                        </archive>
                    </configuration>
                </plugin>

                <!-- maven-failsafe-plugin: -->
                <plugin>
                    <groupId>org.apache.maven.plugins</groupId>
                    <artifactId>maven-failsafe-plugin</artifactId>
                    <version>${maven-failsafe-plugin.version}</version>
                    <executions>
                        <execution>
                            <id>integration-test</id>
                            <goals>
                                <goal>integration-test</goal>
                            </goals>
                        </execution>
                        <execution>
                            <id>verify</id>
                            <goals>
                                <goal>verify</goal>
                            </goals>
                        </execution>
                    </executions>
                </plugin>

                <!-- maven-resources-plugin: -->
                <plugin>
                    <groupId>org.apache.maven.plugins</groupId>
                    <artifactId>maven-resources-plugin</artifactId>
                    <version>${maven-resources-plugin.version}</version>
                </plugin>

                <!-- maven-surefire-plugin: Defined fork mode -->
                <plugin>
                    <groupId>org.apache.maven.plugins</groupId>
                    <artifactId>maven-surefire-plugin</artifactId>
                    <version>${maven-surefire-plugin.version}</version>
                </plugin>

                <!-- maven-compiler-plugin: Defines source, target-version and debug information -->
                <plugin>
                    <groupId>org.apache.maven.plugins</groupId>
                    <artifactId>maven-compiler-plugin</artifactId>
                    <version>${maven-compiler-plugin.version}</version>
                    <configuration>
                        <source>${maven-compiler-plugin.source}</source>
                        <target>${maven-compiler-plugin.target}</target>
                        <debug>${maven-compiler-plugin.debug}</debug>
                    </configuration>
                </plugin>

                <!-- maven-site-plugin: Defines locale of site generation -->
                <plugin>
                    <groupId>org.apache.maven.plugins</groupId>
                    <artifactId>maven-site-plugin</artifactId>
                    <version>${maven-site-plugin.version}</version>
                    <configuration>
                        <locales>${maven-site-plugin.locales}</locales>

                    </configuration>
                    <dependencies>
                        <dependency><!-- add support for ssh/scp -->
                            <groupId>org.apache.maven.wagon</groupId>
                            <artifactId>wagon-ssh</artifactId>
                            <version>${wagon-ssh.version}</version>
                        </dependency>
                        <dependency>
                            <groupId>org.apache.maven.wagon</groupId>
                            <artifactId>wagon-webdav-jackrabbit</artifactId>
                            <version>${wagon-webdav-jackrabbit.version}</version>
                        </dependency>
                    </dependencies>
                </plugin>

                <!-- maven-dependency-plugin: -->
                <plugin>
                    <groupId>org.apache.maven.plugins</groupId>
                    <artifactId>maven-dependency-plugin</artifactId>
                    <version>${maven-dependency-plugin.version}</version>
                </plugin>

                <!-- maven-deploy-plugin: -->
                <plugin>
                    <groupId>org.apache.maven.plugins</groupId>
                    <artifactId>maven-deploy-plugin</artifactId>
                    <version>${maven-deploy-plugin.version}</version>
                    <configuration>
                        <deployAtEnd>${maven-deploy-plugin.deployAtEnd}</deployAtEnd>
                        <altDeploymentRepository>${maven-deploy-plugin.altDeploymentRepository}</altDeploymentRepository>
                        <altReleaseDeploymentRepository>${maven-deploy-plugin.altReleaseDeploymentRepository}</altReleaseDeploymentRepository>
                        <altSnapshotDeploymentRepository>${maven-deploy-plugin.altSnapshotDeploymentRepository}</altSnapshotDeploymentRepository>
                    </configuration>
                </plugin>

                <!-- maven-clean-plugin: -->
                <plugin>
                    <groupId>org.apache.maven.plugins</groupId>
                    <artifactId>maven-clean-plugin</artifactId>
                    <version>${maven-clean-plugin.version}</version>
                </plugin>

                <!-- maven-install-plugin -->
                <plugin>
                    <groupId>org.apache.maven.plugins</groupId>
                    <artifactId>maven-install-plugin</artifactId>
                    <version>${maven-install-plugin.version}</version>
                </plugin>

                <!-- maven-project-info-reports-plugin -->
                <plugin>
                    <groupId>org.apache.maven.plugins</groupId>
                    <artifactId>maven-project-info-reports-plugin</artifactId>
                    <version>${maven-project-info-reports-plugin.version}</version>
                </plugin>

                <!-- maven-pmd-plugin -->
                <plugin>
                    <groupId>org.apache.maven.plugins</groupId>
                    <artifactId>maven-pmd-plugin</artifactId>
                    <version>${maven-pmd-plugin.version}</version>
                    <executions>
                        <execution>
                            <id>pmd</id>
                            <phase>validate</phase>
                            <goals>
                                <goal>check</goal>
                            </goals>
                        </execution>
                    </executions>
                    <dependencies>
                        <dependency>
                            <groupId>ch.dvbern.oss.maven</groupId>
                            <artifactId>code-conventions</artifactId>
                            <version>${code-conventions.version}</version>
                        </dependency>
                    </dependencies>
                    <configuration>
                        <skip>${skip-code-validation}</skip>
                        <failOnViolation>true</failOnViolation>
                        <rulesets>
                            <ruleset>rules/pmd/pmd-rules.xml</ruleset>
                        </rulesets>
                    </configuration>
                </plugin>

                <!-- findbugs-maven-plugin (for backwards compatibility) -->
                <plugin>
                    <groupId>org.codehaus.mojo</groupId>
                    <artifactId>findbugs-maven-plugin</artifactId>
                    <version>${findbugs-maven-plugin.version}</version>
                    <executions>
                        <execution>
                            <id>findbugs</id>
                            <phase>compile</phase>
                            <goals>
                                <goal>check</goal>
                            </goals>
                        </execution>
                    </executions>
                    <dependencies>
                        <dependency>
                            <groupId>ch.dvbern.oss.maven</groupId>
                            <artifactId>code-conventions</artifactId>
                            <version>${code-conventions.version}</version>
                        </dependency>
                    </dependencies>
                    <configuration>
                        <skip>${skip-code-validation}</skip>
                        <!--
						Enables analysis which takes more memory but finds more bugs.
						If you run out of memory, changes the value of the effort element
						to 'Low'.
					    -->
                        <effort>Max</effort>
                        <!-- Reports all bugs (other values are medium and max) -->
                        <threshold>Low</threshold>
                        <!-- Produces XML report -->
                        <xmlOutput>true</xmlOutput>
                        <!-- Configures the directory in which the XML report is created -->
                        <findbugsXmlOutputDirectory>${project.build.directory}/findbugs</findbugsXmlOutputDirectory>
                        <failOnError>true</failOnError>
                        <includeFilterFile>rules/spotbugs/spotbugs-includes.xml</includeFilterFile>
                        <excludeFilterFile>rules/spotbugs/spotbugs-excludes.xml</excludeFilterFile>
                    </configuration>
                </plugin>

                <!-- spotbugs-maven-plugin -->
                <plugin>
                    <groupId>com.github.spotbugs</groupId>
                    <artifactId>spotbugs-maven-plugin</artifactId>
                    <version>${spotbugs-maven-plugin.version}</version>
                    <executions>
                        <execution>
                            <id>spotbugs</id>
                            <phase>compile</phase>
                            <goals>
                                <goal>check</goal>
                            </goals>
                        </execution>
                    </executions>
                    <dependencies>
                        <dependency>
                            <groupId>ch.dvbern.oss.maven</groupId>
                            <artifactId>code-conventions</artifactId>
                            <version>${code-conventions.version}</version>
                        </dependency>
                    </dependencies>
                    <configuration>
                        <skip>${skip-code-validation}</skip>
                        <!--
						Enables analysis which takes more memory but finds more bugs.
						If you run out of memory, changes the value of the effort element
						to 'Low'.
					    -->
                        <effort>Max</effort>
                        <!-- Reports all bugs (other values are medium and max) -->
                        <threshold>Low</threshold>
                        <!-- Produces XML report -->
                        <xmlOutput>true</xmlOutput>
                        <!-- Configures the directory in which the XML report is created -->
                        <spotbugsXmlOutputDirectory>${project.build.directory}/spotbugs</spotbugsXmlOutputDirectory>
                        <failOnError>true</failOnError>
                        <includeFilterFile>rules/spotbugs/spotbugs-includes.xml</includeFilterFile>
                        <excludeFilterFile>rules/spotbugs/spotbugs-excludes.xml</excludeFilterFile>
                    </configuration>
                </plugin>

                <!-- maven-checkstyle-plugin -->
                <plugin>
                    <groupId>org.apache.maven.plugins</groupId>
                    <artifactId>maven-checkstyle-plugin</artifactId>
                    <version>${maven-checkstyle-plugin.version}</version>
                    <configuration>
                        <skip>${skip-code-validation}</skip>
                        <configLocation>rules/checkstyle/checkstyle-rules.xml</configLocation>
                        <suppressionsLocation>rules/checkstyle/checkstyle-suppressions.xml</suppressionsLocation>
                        <suppressionsFileExpression>checkstyle.suppressions.file</suppressionsFileExpression>
                        <consoleOutput>true</consoleOutput>
                        <failsOnError>true</failsOnError>
                        <violationSeverity>info</violationSeverity>
                        <failOnViolation>true</failOnViolation>
                        <excludes>**/target/**/*</excludes>
                    </configuration>
                    <executions>
                        <execution>
                            <id>checkstyle-check</id>
                            <phase>validate</phase>
                            <goals>
                                <goal>check</goal>
                            </goals>
                        </execution>
                    </executions>
                    <dependencies>
                        <dependency>
                            <groupId>com.puppycrawl.tools</groupId>
                            <artifactId>checkstyle</artifactId>
                            <version>${maven-checkstyle.version}</version>
                        </dependency>
                        <dependency>
                            <groupId>ch.dvbern.oss.maven</groupId>
                            <artifactId>code-conventions</artifactId>
                            <version>${code-conventions.version}</version>
                        </dependency>
                    </dependencies>
                </plugin>

                <!-- maven-war-plugin: Defines custom manifest entries when building WARs -->
                <plugin>
                    <groupId>org.apache.maven.plugins</groupId>
                    <artifactId>maven-war-plugin</artifactId>
                    <version>${maven-war-plugin.version}</version>
                    <configuration>
                        <archive>
                            <manifestEntries>
                                <Build-Timestamp>${maven.build.timestamp}</Build-Timestamp>
                                <OS-Name>${os.name}</OS-Name>
                                <Artifact-Name>${project.name}</Artifact-Name>
                                <Version>${project.version}</Version>
                                <Artifact-Group>${project.groupId}</Artifact-Group>
                                <Description>${project.description}</Description>
                            </manifestEntries>
                        </archive>
                    </configuration>
                </plugin>

                <plugin>
                    <groupId>ch.dvbern.oss.maven.jgitflow</groupId>
                    <artifactId>jgitflow-maven-plugin</artifactId>
                    <version>${jgitflow-maven-plugin.version}</version>
                    <configuration>
                        <!-- immer auf den aktuellen Branches bauen -->
                        <pullDevelop>true</pullDevelop>
                        <pullMaster>true</pullMaster>

                        <!-- Multi-Modul-Projekte: Versionsnummern in alle Module uebernehmen -->
                        <autoVersionSubmodules>true</autoVersionSubmodules>

                        <!-- Snapshots sind bei den *-start goals noch erlaubt (z.B. fuer Submodule!),
                        bei den *-finish nicht mehr, siehe unten -->
                        <allowSnapshots>true</allowSnapshots>
                        <allowUntracked>true</allowUntracked>

                        <!-- Build/Deploy wird von CI Server gemacht, nach dem finish werden alle notwendigen Branches/Tags gepusht -->
                        <noReleaseBuild>true</noReleaseBuild>
                        <noHotfixBuild>true</noHotfixBuild>
                        <noFeatureBuild>true</noFeatureBuild>
                        <pushReleases>true</pushReleases>
                        <pushHotfixes>true</pushHotfixes>
                        <pushFeatures>true</pushFeatures>

                        <!-- Diese goals werden bei release-finish ausgefuehrt. (z.B. Enforcer haengt per Default an verify) -->
                        <goals>clean verify</goals>

                        <!-- Fast Forward merges verhindern, gibt schoenere Merge-Trees -->
                        <suppressFastForward>true</suppressFastForward>
                        <!-- Force lf line-endings in pom.xml -->
                        <eol>lf</eol>
                        <!-- Nutzt das SSH-Keystore-Passwort vom OS -->
                        <enableSshAgent>true</enableSshAgent>

                        <flowInitContext>
                            <masterBranchName>master</masterBranchName>
                            <developBranchName>develop</developBranchName>
                            <featureBranchPrefix>feature/</featureBranchPrefix>
                            <releaseBranchPrefix>release/</releaseBranchPrefix>
                            <hotfixBranchPrefix>hotfix/</hotfixBranchPrefix>
                            <versionTagPrefix />
                        </flowInitContext>
                    </configuration>
                    <dependencies>
                        <dependency>
                            <!-- Use secure crypto algorithms: https://ecosystem.atlassian.net/browse/MJF-299 -->
                            <groupId>com.jcraft</groupId>
                            <artifactId>jsch</artifactId>
                            <version>0.1.55</version>
                        </dependency>
                    </dependencies>
                    <executions>
                        <execution>
                            <goals>
                                <goal>release-finish</goal>
                                <goal>hotfix-finish</goal>
                            </goals>
                            <configuration>
                                <allowSnapshots>false</allowSnapshots>
                            </configuration>
                        </execution>
                    </executions>
                </plugin>

                <plugin>
                    <groupId>org.apache.maven.plugins</groupId>
                    <artifactId>maven-source-plugin</artifactId>
                    <version>${maven-source-plugin.version}</version>
                </plugin>

                <plugin>
                    <groupId>org.apache.maven.plugins</groupId>
                    <artifactId>maven-javadoc-plugin</artifactId>
                    <version>${maven-javadoc-plugin.version}</version>
                    <configuration>
                        <doclint>all,-missing</doclint>
                        <skip>${skip-javadoc}</skip>
                    </configuration>
                </plugin>

                <plugin>
                    <groupId>org.apache.maven.plugins</groupId>
                    <artifactId>maven-enforcer-plugin</artifactId>
                    <version>${maven-enforcer-plugin.version}</version>
                    <configuration>
                        <skip>${maven-enforcer-plugin.skip}</skip>
                        <rules>
                            <requirePluginVersions>
                                <unCheckedPlugins>${maven-enforcer-plugin.requirePluginVersions.unCheckedPlugins}</unCheckedPlugins>
                                <additionalPlugins>${maven-enforcer-plugin.requirePluginVersions.additionalPlugins}</additionalPlugins>
                                <phases>${maven-enforcer-plugin.requireReleaseDeps.phases}</phases>
                            </requirePluginVersions>
                            <requireReleaseDeps>
                                <failWhenParentIsSnapshot>${maven-enforcer-plugin.requireReleaseDeps.failWhenParentIsSnapshot}</failWhenParentIsSnapshot>
                                <onlyWhenRelease>${maven-enforcer-plugin.requireReleaseDeps.onlyWhenRelease}</onlyWhenRelease>
                                <searchTransitive>${maven-enforcer-plugin.requireReleaseDeps.searchTransitive}</searchTransitive>
                            </requireReleaseDeps>
                            <evaluateBeanshell>
                                <condition>${maven-enforcer-plugin.evaluateBeanshell.condition}</condition>
                            </evaluateBeanshell>
                            <requireMavenVersion>
                                <version>${maven-enforcer-plugin.requireMavenVersion.version}</version>
                            </requireMavenVersion>
                        </rules>
                        <fail>true</fail>
                    </configuration>
                </plugin>

            </plugins>
        </pluginManagement>

        <plugins>
            <!-- maven-source-plugin: Always create a source.jar where applicable -->
            <plugin>
                <groupId>org.apache.maven.plugins</groupId>
                <artifactId>maven-source-plugin</artifactId>
                <executions>
                    <execution>
                        <id>attach-sources</id>
                        <phase>verify</phase>
                        <goals>
                            <goal>jar-no-fork</goal>
                        </goals>
                    </execution>
                </executions>
            </plugin>

            <!-- maven-javadoc-plugin -->
            <plugin>
                <groupId>org.apache.maven.plugins</groupId>
                <artifactId>maven-javadoc-plugin</artifactId>
                <executions>
                    <execution>
                        <id>attach-javadocs</id>
                        <goals>
                            <goal>jar</goal>
                        </goals>
                    </execution>
                    <!-- configuration: see jenkins settings.xml -->
                </executions>
            </plugin>

            <!-- maven-enforcer-plugin: Enforces use of Non-Snapshot-Plugins, proper dependency management and require maven version. -->
            <plugin>
                <groupId>org.apache.maven.plugins</groupId>
                <artifactId>maven-enforcer-plugin</artifactId>
                <executions>
                    <execution>
                        <id>enforce</id>
                        <goals>
                            <goal>enforce</goal>
                        </goals>
                    </execution>
                </executions>
            </plugin>

        </plugins>
    </build>

    <reporting>
        <plugins>
            <plugin>
                <groupId>org.apache.maven.plugins</groupId>
                <artifactId>maven-jxr-plugin</artifactId>
                <version>${maven-jxr-plugin.version}</version>
            </plugin>
            <plugin>
                <groupId>org.codehaus.mojo</groupId>
                <artifactId>taglist-maven-plugin</artifactId>
                <version>${taglist-maven-plugin.version}</version>
                <configuration>
                    <tags>
                        <tag>TODO</tag>
                        <tag>FIXME</tag>
                        <tag>REVIEW</tag>
                        <tag>@todo</tag>
                    </tags>
                </configuration>
            </plugin>
            <plugin>
                <groupId>org.apache.maven.plugins</groupId>
                <artifactId>maven-surefire-report-plugin</artifactId>
                <version>${maven-surefire-report-plugin.version}</version>
                <configuration>
                    <showSuccess>false</showSuccess>
                    <fork>true</fork>
                </configuration>
            </plugin>
        </plugins>
    </reporting>

    <distributionManagement>
        <repository>
            <id>${maven.repo.releases.oss.id}</id>
            <name>DV Bern Release Repository</name>
            <url>${maven.repo.releases.oss.url}</url>
        </repository>
        <snapshotRepository>
            <id>${maven.repo.snapshots.oss.id}</id>
            <name>DV Bern Snapshots Repository</name>
            <layout>default</layout>
            <url>${maven.repo.snapshots.oss.url}</url>
            <uniqueVersion>true</uniqueVersion>
        </snapshotRepository>
        <site>
            <id>${maven.repo.sites.oss.id}</id>
            <name>DV Bern Projektseiten</name>
            <url>${maven.repo.sites.oss.url}</url>
        </site>
    </distributionManagement>

    <!-- The properties section is the place where this parent pom may be customized. -->
    <properties>
        <!-- backwards compatibility to the old maven-timestamp-plugin -->
        <timestamp>${maven.build.timestamp}</timestamp>

        <!--
			  ===========================================================================================
			  Global settings
			  ===========================================================================================
		-->
        <!-- Repo IDs/URLs-->
        <maven.repo.releases.oss.id>dvb.oss</maven.repo.releases.oss.id>
        <maven.repo.releases.oss.url>releases-url-set-by-CI</maven.repo.releases.oss.url>
        <maven.repo.snapshots.oss.id>dvb.oss.snapshots</maven.repo.snapshots.oss.id>
        <maven.repo.snapshots.oss.url>snapshots-url-set-by-CI</maven.repo.snapshots.oss.url>
        <maven.repo.sites.oss.id>dvb.oss.sites</maven.repo.sites.oss.id>
        <maven.repo.sites.oss.url>site-url-set-by-CI</maven.repo.sites.oss.url>

        <!--
			  Encoding settings Defines the encoding used on java source files and
			  encoding to be used when generating reportings.
		-->
        <project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
        <project.reporting.outputEncoding>UTF-8</project.reporting.outputEncoding>

        <!--
			  ===========================================================================================
			  Dependency Management Versions
			  ===========================================================================================
		-->
        <wagon-ssh.version>3.5.3</wagon-ssh.version>
        <wagon-webdav-jackrabbit.version>3.5.3</wagon-webdav-jackrabbit.version>

        <!--
			  ===========================================================================================
			  Plugin customization
			  ===========================================================================================
		-->
        <skipTests />
        <skip-code-validation />
        <skip-javadoc />

        <!--
        Diese Version muss der ${project.version} entsprechen. Leider kann sie nicht per Variable
        ${project.version} gesetzt werden, weil dann erbende Projekte die ${project.version} überschreiben.
         -->
        <code-conventions.version>5.0.0</code-conventions.version>
        <code-conventions.release.version>5.0.0</code-conventions.release.version>

        <!-- spotbugs-maven-plugin -->
        <spotbugs-maven-plugin.version>4.7.3.0</spotbugs-maven-plugin.version>

        <!-- maven-checkstyle-plugin -->
        <maven-checkstyle-plugin.version>3.2.1</maven-checkstyle-plugin.version>
        <maven-checkstyle.version>10.7.0</maven-checkstyle.version>

        <!-- maven-clean-plugin -->
        <maven-clean-plugin.version>3.2.0</maven-clean-plugin.version>

        <!-- maven-compiler-plugin -->
        <maven-compiler-plugin.version>3.10.1</maven-compiler-plugin.version>
        <maven-compiler-plugin.target>1.8</maven-compiler-plugin.target>
        <maven-compiler-plugin.source>1.8</maven-compiler-plugin.source>
        <maven-compiler-plugin.debug>true</maven-compiler-plugin.debug>

        <!-- maven-dependency-plugin -->
        <maven-dependency-plugin.version>3.5.0</maven-dependency-plugin.version>

        <!-- maven-deploy-plugin -->
        <maven-deploy-plugin.version>3.1.0</maven-deploy-plugin.version>
        <maven-deploy-plugin.deployAtEnd>true</maven-deploy-plugin.deployAtEnd>
        <maven-deploy-plugin.skip>false</maven-deploy-plugin.skip>
        <maven-deploy-plugin.altDeploymentRepository />
        <maven-deploy-plugin.altReleaseDeploymentRepository />
        <maven-deploy-plugin.altSnapshotDeploymentRepository />

        <!-- maven-ear-plugin -->
        <maven-ear-plugin.version>3.3.0</maven-ear-plugin.version>

        <!-- maven-ejb-plugin -->
        <maven-ejb-plugin.version>3.2.1</maven-ejb-plugin.version>

        <!-- maven-enforcer-plugin -->
        <maven-enforcer-plugin.version>3.2.1</maven-enforcer-plugin.version>
        <!-- If set to true, enforcing rules are skipped. -->
        <maven-enforcer-plugin.skip>false</maven-enforcer-plugin.skip>
        <!-- If set to false, even SNAPSHOT version may not define SNAPSHOT dependencies. -->
        <maven-enforcer-plugin.requireReleaseDeps.onlyWhenRelease>true</maven-enforcer-plugin.requireReleaseDeps.onlyWhenRelease>
        <!-- if the parent should be checked. Default: true -->
        <maven-enforcer-plugin.requireReleaseDeps.failWhenParentIsSnapshot>true</maven-enforcer-plugin.requireReleaseDeps.failWhenParentIsSnapshot>
        <!-- if transitive dependencies should be checked. Default: true -->
        <maven-enforcer-plugin.requireReleaseDeps.searchTransitive>true</maven-enforcer-plugin.requireReleaseDeps.searchTransitive>
        <!--
			  The comma separated list of phases that should be used to find
			  lifecycle plugin bindings. The default value is "clean,deploy,site".
		-->
        <maven-enforcer-plugin.requireReleaseDeps.phases>clean,deploy,site</maven-enforcer-plugin.requireReleaseDeps.phases>

        <!--
			A comma separated list of plugins to skip version checking. Ie allow
			no version, or snapshots, etc. The plugins should be specified in the
			form: group:artifactId.
		-->
        <maven-enforcer-plugin.requirePluginVersions.unCheckedPlugins />
        <!--
		  A list of additional plugins to enforce have versions. These are
		  plugins that may not be in the poms but are used anyway, like help,
		  eclipse etc. The plugins should be specified in the form:
		  group:artifactId.
		-->
        <maven-enforcer-plugin.requirePluginVersions.additionalPlugins />
        <!--
					  Beanshell (http://www.beanshell.org/) Script. Can be used to write ad-hoc enforcing rules. Example:


					  String userDir = System.getProperty("user.dir");
					  if (!userDir.equals("${basedir}")) {
						  print("Bitte Build vom Basisverzeichnis des Projektes starten!");
						  return false;
					  }
					  return true;

					  Defaults to "true"

		-->
        <maven-enforcer-plugin.evaluateBeanshell.condition>true</maven-enforcer-plugin.evaluateBeanshell.condition>

        <!-- Supported maven version -->
        <maven-enforcer-plugin.requireMavenVersion.version>[3.8.7,)</maven-enforcer-plugin.requireMavenVersion.version>

        <!-- maven-failsafe-plugin -->
        <maven-failsafe-plugin.version>3.0.0-M9</maven-failsafe-plugin.version>

        <!-- maven-gpg-plugin -->
        <maven-gpg-plugin.version>3.0.1</maven-gpg-plugin.version>

        <!-- maven-install-plugin -->
        <maven-install-plugin.version>3.1.0</maven-install-plugin.version>

        <!-- maven-versions-plugin -->
        <versions-maven-plugin.version>2.14.2</versions-maven-plugin.version>

        <!-- maven-jar-plugin -->
        <maven-jar-plugin.version>3.3.0</maven-jar-plugin.version>

        <!-- maven-javadoc-plugin -->
        <maven-javadoc-plugin.version>3.5.0</maven-javadoc-plugin.version>

        <!-- maven-jxr-plugin -->
        <maven-jxr-plugin.version>3.3.0</maven-jxr-plugin.version>

        <!-- maven-pmd-plugin -->
        <maven-pmd-plugin.version>3.20.0</maven-pmd-plugin.version>

        <!-- maven-project-info-reports-plugin -->
        <maven-project-info-reports-plugin.version>3.4.2</maven-project-info-reports-plugin.version>

        <!-- maven-resources-plugin -->
        <maven-resources-plugin.version>3.3.0</maven-resources-plugin.version>

        <!-- maven-site-plugin -->
        <maven-site-plugin.version>4.0.0-M5</maven-site-plugin.version>
        <maven-site-plugin.locales>de_CH</maven-site-plugin.locales>
        <maven-site-plugin.skip>false</maven-site-plugin.skip>
        <maven-site-plugin.skipDeploy>false</maven-site-plugin.skipDeploy>

        <!-- maven-source-plugin -->
        <maven-source-plugin.version>3.2.1</maven-source-plugin.version>

        <!-- maven-surefire-plugin -->
        <maven-surefire-plugin.version>3.0.0-M9</maven-surefire-plugin.version>

        <!-- maven-surefire-report-plugin -->
        <maven-surefire-report-plugin.version>3.0.0-M9</maven-surefire-report-plugin.version>

        <!-- maven-war-plugin -->
        <maven-war-plugin.version>3.3.2</maven-war-plugin.version>

        <!-- findbugs-maven-plugin -->
        <findbugs-maven-plugin.version>3.0.5</findbugs-maven-plugin.version>

        <!-- taglist-maven-plugin -->
        <taglist-maven-plugin.version>3.0.0</taglist-maven-plugin.version>

        <!-- jgitflow-maven-plugin -->
        <jgitflow-maven-plugin.version>1.0-m9</jgitflow-maven-plugin.version>

        <!-- nexus-staging-maven-plugin -->
        <nexus-staging-maven-plugin.version>1.6.13</nexus-staging-maven-plugin.version>
    </properties>

</project>
