Error using checkstyle/google_checks.xml with maven-checkstyle-plugin

二次信任 提交于 2019-12-01 16:37:25
ccDict

fixed this by updating the checkstyle-dependency manually to the latest stable version:

        <plugin>
            <groupId>org.apache.maven.plugins</groupId>
            <artifactId>maven-checkstyle-plugin</artifactId>
            <version>2.13</version>
            <dependencies>
                <dependency>
                    <groupId>com.puppycrawl.tools</groupId>
                    <artifactId>checkstyle</artifactId>
                    <version>${checkstyle.latest.version}</version>
                </dependency>
            </dependencies>
            <configuration>
                <configLocation>${checkstyle.file.path}</configLocation>
                <failOnViolation>false</failOnViolation>
            </configuration>
        </plugin>

Maven checkstyle plugin uses checkstyle 5.7 (the first line of plugin description).

Checkstyle 5.7 does not have this check (see checks package on grepcode).

You need either to disable this check or to wait for official fix of MCHECKSTYLE-261.

I give a demo at

https://github.com/favoorr/Maven-Checkstyle-Multimodule-Use

Multi modules and use Google Chechstyle

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!