To run sonar, either we can directly run using maven script or we can run sonar from eclipse plugins.
To run sonar report, first we have to install maven & sonar in our local machine.
- Download and extract Maven in your C drive from http://www.apache.org/dyn/closer.cgi/maven/binaries/apache-maven-3.0.4-bin.zip
- Install Jdk
- Download and extract Sonar in your D drive from http://dist.sonar.codehaus.org/sonar-3.0.zip
- Now go to D:\sonar-3.0\bin\windows-x86-32 and double click on StartSonar.batNow sonar server will start locally on http://localhost:9000
- Go to parent folder of your project, and run following command
mvn clean compile install sonar:sonar as below - After its completion, browse http://localhost:9000/ where you will see the project list with code quality report as below
No comments:
Post a Comment