<?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">
    <modelVersion>4.0.0</modelVersion>

    <parent>
        <groupId>com.keyware.sonar</groupId>
        <artifactId>sonar-keyware-plugins</artifactId>
        <version>1.0-SNAPSHOT</version>
    </parent>

    <name>C++ 信息安全性设计准则</name>
    <artifactId>sonar-keyware-plugins-cxx</artifactId>
    <version>1.0-SNAPSHOT</version>
    <description>用于检查C++源代码的安全性设计准则的Sonarqube插件</description>

    <properties>
        <java.version>11</java.version>
        <commons-io.version>2.15.1</commons-io.version>
        <commons-lang.version>2.6</commons-lang.version>
        <!-- we depend on API ${sonar.version} but we keep backward compatibility with LTS -->
        <sonar.version>9.9.0.65466</sonar.version>
        <sonar.plugin.api.version>9.14.0.375</sonar.plugin.api.version>
        <sonarQubeMinVersion>8.9</sonarQubeMinVersion>
        <gson.version>2.10.1</gson.version>
        <guava.version>33.0.0-jre</guava.version>
        <jsr305.version>3.0.2</jsr305.version>
        <mockito-all.version>1.10.19</mockito-all.version>
        <mockito-core.version>5.8.0</mockito-core.version>
        <assertj-core.version>3.24.2</assertj-core.version>
        <junit-jupiter.version>5.10.1</junit-jupiter.version>
    </properties>

    <dependencies>
        <dependency>
            <groupId>org.sonarsource.sonarqube-plugins.cxx</groupId>
            <artifactId>cxx-sslr-toolkit</artifactId>
            <systemPath>${project.basedir}/libs/cxx-sslr-toolkit-2.1.1.488.jar</systemPath>
            <version>2.1.1.488</version>
            <scope>system</scope>
        </dependency>
        <dependency>
            <groupId>org.sonarsource.sonarqube-plugins.cxx</groupId>
            <artifactId>sonar-cxx-plugin</artifactId>
            <systemPath>${project.basedir}/libs/sonar-cxx-plugin-2.1.1.488.jar</systemPath>
            <version>2.1.1.488</version>
            <scope>system</scope>
        </dependency>

        <dependency>
            <groupId>org.sonarsource.api.plugin</groupId>
            <artifactId>sonar-plugin-api</artifactId>
            <version>${sonar.plugin.api.version}</version>
        </dependency>

        <dependency>
            <groupId>org.sonarsource.sonarqube</groupId>
            <artifactId>sonar-plugin-api-impl</artifactId>
            <version>${sonar.version}</version>
            <scope>compile</scope>
        </dependency>

        <dependency>
            <groupId>commons-io</groupId>
            <artifactId>commons-io</artifactId>
            <version>${commons-io.version}</version>
            <scope>test</scope>
        </dependency>
        <dependency>
            <groupId>commons-lang</groupId>
            <artifactId>commons-lang</artifactId>
            <version>${commons-lang.version}</version>
        </dependency>
        <dependency>
            <groupId>com.google.code.findbugs</groupId>
            <artifactId>jsr305</artifactId>
            <version>${jsr305.version}</version>
        </dependency>
        <dependency>
            <groupId>com.google.guava</groupId>
            <artifactId>guava</artifactId>
            <version>${guava.version}</version>
        </dependency>
        <dependency>
            <groupId>com.google.code.gson</groupId>
            <artifactId>gson</artifactId>
            <version>${gson.version}</version>
        </dependency>
        <dependency>
            <groupId>org.mockito</groupId>
            <artifactId>mockito-core</artifactId>
            <version>${mockito-core.version}</version>
            <scope>test</scope>
        </dependency>
        <dependency>
            <groupId>org.assertj</groupId>
            <artifactId>assertj-core</artifactId>
            <version>${assertj-core.version}</version>
            <scope>test</scope>
        </dependency>
        <dependency>
            <groupId>org.junit.jupiter</groupId>
            <artifactId>junit-jupiter-api</artifactId>
            <version>${junit-jupiter.version}</version>
            <scope>test</scope>
        </dependency>
        <dependency>
            <groupId>org.junit.jupiter</groupId>
            <artifactId>junit-jupiter-engine</artifactId>
            <version>${junit-jupiter.version}</version>
            <scope>test</scope>
        </dependency>
    </dependencies>


    <build>
        <plugins>
            <plugin>
                <groupId>org.sonarsource.sonar-packaging-maven-plugin</groupId>
                <artifactId>sonar-packaging-maven-plugin</artifactId>
                <configuration>
                    <sonarQubeMinVersion>${sonarQubeMinVersion}</sonarQubeMinVersion>
                </configuration>
            </plugin>

            <plugin>
                <groupId>com.mycila</groupId>
                <artifactId>license-maven-plugin</artifactId>
                <configuration>
                    <header>${project.basedir}/src/main/resources/license-header.txt</header>
                    <!--排除文件-->
                    <excludes>
                        <exclude>**/*.properties</exclude>
                        <exclude>*.sh</exclude>
                        <exclude>*.yml</exclude>
                        <exclude>.editorconfig</exclude>
                        <exclude>.gitignore</exclude>
                        <exclude>**/*.md</exclude>
                        <exclude>**/*.xml</exclude>
                    </excludes>
                </configuration>
            </plugin>
        </plugins>
        <resources>
            <resource>
                <directory>src/main/resources</directory>
                <excludes>
                    <exclude>com/sonar/sqale/cxx-model-project*</exclude>
                    <exclude>external/*</exclude>
                </excludes>
            </resource>
        </resources>
    </build>
</project>