Using SonarQube in Eclipse

60,737

Solution 1

To be able to use Sonar Eclipse, you first need to install a Sonar server 5.1 or older as described here: http://docs.sonarqube.org/display/SONAR/SonarQube+in+Eclipse

Then, you will have to run a first analysis (out of Eclipse) of your project to have it referenced in the Sonar server. See http://docs.sonarqube.org/display/SONAR/Analyzing+Source+Code

After those 2 steps, then you'll be able to run analyses directly within Eclipse once you have associated your local project with the Sonar server.

UPDATE: Sonar 5.2+ is no longer supporting sonar eclipse plugin in favor of sonarlint. Unfortunately sonarlint has no customization options.

We will make this feature available in upcoming versions, probably by requiring to "connect" SonarLint with an existing SonarQube server instance.

Solution 2

Sonar can be run now localy to analyse the java project

for more information visit sonar eclipse

Also you can visit DZONE for step by step installation procedure

Share:
60,737
akram
Author by

akram

Updated on May 13, 2020

Comments

  • akram
    akram about 4 years

    I just installed SonarQube in Eclipse, but I don't know how to use it :

    Here It said: Link projects to Sonar server

    What is the server? Should we create another project somewhere else with the same name as the project in Eclipse?

    It's really confusing, I will appreciate if someone could help by a small example.