IDEA SonarLint installation and use

SonarLint installation prompt requires JDK8. JDK7 is not tested and cannot guarantee success.

SonarLint plugin installation

  1. Select File->Settings in the IDEA menu bar, and select Plugins in the left column
    IDEA Setting

  2. For online installation, select Browse repositories, search for Sonar, select SonarLint to install, and then restart IDEA
    IDEA SonarLint

IDEA SonarLint use

  1. After installing the SonarLint plugin and restarting, the SonarLint View will appear in the IDEA Tool Windows section. If it does not appear, select the menu View->Tool Windows->SonarLint will display
    IDEA SonarLint use

    After SonarLint is installed, it automatically detects the project code by default. If you think it affects the efficiency, you can set it through the menu Settings->Other Settings->SonarLint General Settings
    IDEA SonarLint Automatic

  2. When manually detecting the code, select Scope in Tool Windows (you can choose All project files or VCS changed files), and then click the Analyze button on the left to detect
    IDEA SonarLint Manual Anylyze

  3. After the detection is completed, the detected problems will be displayed in the SonarLint Tool View and classified by class name. Various types of issues are divided into blocking, serious, major, prompt, and minor, and the severity of the problem decreases in turn. Click issue, the corresponding Rule will appear on the right side, you can refer to it for modification
    IDEA SonarLint Issue

Eclipse SonarLint installation and use

For the installation and use of Eclipse SonarLint, please refer to the installation and use of the SonarLint plug-in

more info

  1. SonarLint

Guess you like

Origin http://43.154.161.224:23101/article/api/json?id=326008387&siteId=291194637