Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.
Info
iconfalse
titleTable of Contents
Table of Contents
maxLevel1

To configure the settings for a project, it is necessary to connect as an administrator on this project (See SecurityProject administration is accessible through the Configuration menu.

Image Added

Only project administrators can access project settings (See Authorization).

Adding a Project

Adding a A project to Sonar is not done through the web interface, but automatically when the project is automatically added to SonarQube when analyzed for the first time. Note that you can also provision projects.

Deleting a Project

You can delete a project in Sonar by clicking on Project Deletion in the left menu.through Configuration > Deletion:

Note also that a service to delete several projects at the same time is available since Sonar 3.2. projects can also be deleted in bulk.

Updating Project Key

Since Sonar 3.2, the The project key can be updated (without losing the history on the project). Go to Configuration > Update Key:

 

Setting Quality Profiles

As Sonar 3.3 enables multi-language project analysis, project administrators can select which quality profile to use for each language on their project. Go to Configuration > Quality Profiles:

Image Removed

Excluding Resources

It is possible to exclude source code from being analyzed:

  • Since Sonar 3.3, go to Configuration > Settings > Exclusions and set the 'sonar.exclusions' property.
  • For Sonar versions prior to 3.3, click on Exclusions in the left menu and set the 'sonar.exclusions' property.
Since Sonar 3.3, it is also possible to:
  • Exclude tests file from being analyzed: go to Configuration > Settings > Exclusions and set the 'sonar.tests.exclusions' property
  • Set global exclusions that will apply to all the projects: go to Configuration > General Settings > Exclusions and set the 'sonar.global.exclusions' and 'sonar.global.tests.exclusions' properties.

To exclude files, you can use wildcard patterns. Example: **/*Bean.java to exclude all classes ending with the Bean word. Full documentation is directly available on the Exclusions administration Sonar web interface.

...

titleCoding rules

...

The new key must match the following regular expression: [0-9a-zA-Z:-_\.:]+

Note that the validity of the new key is not currently verified. See 

JIRA
serverjira.codehaus.org
keySONAR-4770
.

Setting Quality Profiles and Quality Gate

Project administrators can select which:

  • Quality profiles (go to Configuration > Quality Profiles)
  • Quality gate (go to Configuration > Quality Gate)

 to use on their project.

Setting Exclusions

See Narrowing the Focus.

Customizing Links

To add links to your project, click on Links in the left menugo to Configuration > Links:

They are two types of links:

These links have to be defined in the analysis configuration file:

  • Home: sonar.links.homepage
  • Continuous integration: sonar.links.ci
  • Issue tracker: sonar.links.issue
  • Sources: sonar.links.scm
  • Developer connection: sonar.links.scm_dev

For Maven projects, these links are retrieved from the project POM:

  • Home: <url>
  • Continuous integration: <ciManagement><url> <ciManagement><url>
  • Issue tracker: <issueManagement><url> <issueManagement><url>
  • Sources: <scm><url>
  • Developer connection: <scm><developerConnection>
Setting a sonar.links.* property on a Maven project overrides the one above.

...

They can not be modified through the web interface.

Any link can be added trough through the web interface.Those  Those links can be displayed on a dashboard by adding the Description widget.

Configuring Plugins

Several plugins can be configured at project level to override Global Settings for that project.On your project, click on Settings in the left menuthe plugin's global settings. Go to Configuration > Settings.