configuration-as-code-plugin/demos/warnings
René Scheibe 74c7d1a4e6 Improve documenation 2019-03-05 22:00:28 +01:00
..
README.md Improve documenation 2019-03-05 22:00:28 +01:00

README.md

warnings-plugin

Supported in plugin version >= 5.00

Now present in the new Groovy Based Warnings Parsers section.

sample-configuration (Example parser from help)

unclassified:
  warningsParsers:
    parsers:
      - name: "Example parser"
        id: example-id
        regexp: "^\\s*(.*):(\\d+):(.*):\\s*(.*)$"
        script: |
          import edu.hm.hafner.analysis.Severity
          builder.setFileName(matcher.group(1))
                  .setLineStart(Integer.parseInt(matcher.group(2)))
                  .setSeverity(Severity.WARNING_NORMAL)
                  .setCategory(matcher.group(3))
                  .setMessage(matcher.group(4))
          return builder.buildOptional();          
        example: "somefile.txt:2:SeriousWarnings:SomethingWentWrong"