Uploaded image for project: 'Maven Checkstyle Plugin'
  1. Maven Checkstyle Plugin
  2. MCHECKSTYLE-182

Use Maven log levels when logging to console

Attach filesAttach ScreenshotVotersWatch issueWatchersCreate sub-taskLinkCloneUpdate Comment AuthorReplace String in CommentUpdate Comment VisibilityDelete Comments
    XMLWordPrintableJSON

Details

    • Improvement
    • Status: Closed
    • Minor
    • Resolution: Fixed
    • 2.9.1
    • 2.12
    • checkstyle:check
    • None

    Description

      Getting checkstyle:check to print out Checkstyle's findings to the console during a build is surprisingly hard/ugly:

      <violationSeverity>info</violationSeverity>
      <failOnViolation>false</failOnViolation>
      <logViolationsToConsole>true</logViolationsToConsole>
      

      While this achieves the desired effect, it produces a warning:

      [WARNING] checkstyle:check violations detected but failOnViolation set to false
      

      Moreover, all found violations, whether errors, warnings, or infos, are logged as [ERROR]'s on Maven's console. It would be nice if the maven-checkstyle-plugin would use the corresponding Maven log levels instead.

      Attachments

        Issue Links

        Activity

          This comment will be Viewable by All Users Viewable by All Users
          Cancel

          People

            dennisl@apache.org Dennis Lundberg
            sewe Andreas Sewe
            Votes:
            0 Vote for this issue
            Watchers:
            3 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved:

              Slack

                Issue deployment