SonarQube Ant Project Configuration

 

1.Install & Configure apache ant on your local system

 

2.Download Sonar-ant-task.jar and place the jar file in apache-ant-1.10.0\lib folder

 

3.Chose the Java ant Project for Analyzing Source Code. Ex: LoginAnt as below

 

4.Open Build.xml & Configure sonar details as below

 

 

5.Run SonarQube by Starting C:\DevOps\sonarqube\bin\windows-x86-64\StartSonar.bat

 

6.Open SonarQube Dashboard on http://localhost:9000

 

7.Navigate to Project root directory/build directory & run below command

ant sonar

 

8.Now the complete SONAR Report will be displayed on http://localhost:9000