<?xml version="1.0" encoding="UTF-8"?>
<!--
  ~ Copyright 2015 Slawomir Jaranowski
  ~
  ~ 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.
  ~ See the License for the specific language governing permissions and
  ~ 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 http://maven.apache.org/xsd/maven-4.0.0.xsd">
    <modelVersion>4.0.0</modelVersion>

    <parent>
        <groupId>com.github.s4u</groupId>
        <artifactId>parent-root</artifactId>
        <version>2.0.0</version>
    </parent>

    <artifactId>parent</artifactId>
    <packaging>pom</packaging>

    <name>Simplify4U parent POM</name>
    <description>Simplify4U parent POM for our projects</description>

    <build>

        <plugins>

            <!-- check code rules -->
            <plugin>
                <groupId>org.apache.maven.plugins</groupId>
                <artifactId>maven-checkstyle-plugin</artifactId>
                <configuration>
                    <configLocation>/s4u/sec-rules/checkstyle.xml</configLocation>
                    <failOnViolation>true</failOnViolation>
                    <failsOnError>true</failsOnError>
                    <logViolationsToConsole>true</logViolationsToConsole>
                    <consoleOutput>true</consoleOutput>
                    <includeTestSourceDirectory>true</includeTestSourceDirectory>
                    <linkXRef>false</linkXRef>
                    <sourceDirectory>${project.build.sourceDirectory}</sourceDirectory>
                    <testSourceDirectory>${project.build.testSourceDirectory}</testSourceDirectory>
                </configuration>
                <dependencies>
                    <dependency>
                        <groupId>com.github.s4u</groupId>
                        <artifactId>parent-sec-rules</artifactId>
                        <version>2.0.0</version>
                    </dependency>
                </dependencies>
                <executions>
                    <execution>
                        <id>id-checkstyle</id>
                        <goals>
                            <goal>check</goal>
                        </goals>
                    </execution>
                </executions>
            </plugin>

            <plugin>
                <groupId>org.apache.maven.plugins</groupId>
                <artifactId>maven-pmd-plugin</artifactId>
                <configuration>
                    <printFailingErrors>true</printFailingErrors>
                    <linkXRef>false</linkXRef>
                    <targetJdk>${maven.compiler.source}</targetJdk>
                    <rulesets>
                        <ruleset>/s4u/sec-rules/pmd.xml</ruleset>
                    </rulesets>
                </configuration>
                <dependencies>
                    <dependency>
                        <groupId>com.github.s4u</groupId>
                        <artifactId>parent-sec-rules</artifactId>
                        <version>2.0.0</version>
                    </dependency>
                </dependencies>
                <executions>
                    <execution>
                        <id>id-pmd</id>
                        <goals>
                            <goal>check</goal>
                            <goal>cpd-check</goal>
                        </goals>
                    </execution>
                </executions>
            </plugin>
        </plugins>
    </build>

</project>
