Your project home page shows where you stand in terms of quality in a glimpse of an eye. This main page also shows you an immediate sense of the good results achieved over time.
Focus on the Leak
The water leak paradigm is a simple yet powerful way to manage code quality: quality of new - changed and added - code should be put under control before anything else.
Once that Leak is under control, code quality will start improving systematically. In SonarQube, the Leak is a built-in concept that you can’t miss. Once you’ve had a look at this yellow area on the left of your project home page, you will always remain focused on it to not miss any new issues.
Enforce Quality Gate
With SonarQube, a developer has everything at hand to take ownership of the quality of his code. To fully enforce a code quality practice across all teams, you need to set up a Quality Gate.
This core concept of SonarQube is a set of requirements that tells whether or not a new version of a project can go into production. SonarQube’s default Quality Gate checks what happened on the Leak period and fails if your new code got worse in this period.
Analyze pull requests
Once you have SonarQube in place, you will quickly want to make sure you add as few issues as possible to your code base.
To shorten the feedback loop so you don’t have to wait for new analyses to be available on SonarQube, you can set up the analysis of your pull requests.
Analyses will be run on your feature branches without being pushed to SonarQube, giving you the opportunity to fix issues before they ever reach SonarQube!
Track the quality of short-lived and long-lived code branches in SonarQube to ensure that only clean, approved code gets merged into master.
Dig into issues
The “Issues” page of your project gives you full power to analyze in detail what the main issues are, where they are located, when they were added to your code base and who originally introduced them.
Specifically, you can be notified via email when you introduce new issues, then you simply click on the link in the email to see the set of new issues assigned to you for review.
Highlight hot spots
SonarQube treats test coverage and duplications, two of the major software quality problems, as first class citizens.
The “Measures” page lets you browse your project in different ways to highlight files that need your attention. More generally, for each main domain SonarQube provides a bubble chart that correlates different metrics to highlight other potential hot spots.
Visualise the history of a project
Thanks to the Activity page you can dig into the details of the history of your project very easily and precisely to better understand what happened in the past.
Use graphs and visualisations to track project quality over time and zoom in on specific time periods for more granular analysis.