CheckStyle plugin for IDEA - java way of warnings presentation and automatic fixes?

后端 未结 1 1267
眼角桃花
眼角桃花 2021-01-01 03:14
  1. Is it possible to make it present the list of warnings java/spellchecker style as opposed to a old school list of errors with line numbers?
  2. Can it automatical
相关标签:
1条回答
  • 2021-01-01 04:10

    Try QAPlug - Checkstyle plugin. Then go Analyze - Analyze Code (not the standard Analyze!) then click "..." near Run with chosen profile select a concrete profile and press the import button.

    enter image description here

    In the next dialog select the checkstyle rules file and then click the OK button. That's it. Just wait for the results. I got something like this.

    enter image description here

    That plugin has its limitations however. For example, I didn't manage to use a file with suppressions with it.

    You can also use the plugin CheckStyle-IDEA which also has good configurations and allows you to use suppressions, custom checks and displays the inspection warnings in the editor immediately, but to apply that you need to set Project Settings - Inspections - CheckStyle - Real-Time Scan in the IDE settins.

    enter image description here

    enter image description here

    Answering the second question, I didn't find any automatical reformat capabilities in these plugins, just checks.

    0 讨论(0)
提交回复
热议问题