Skip to content

Authentication and configuration

Costa Jorge edited this page Apr 1, 2016 · 19 revisions

Extension settings are available via Sonar menu in visual studio.

Image

It opens the VSSonarQube Options dialog

Image

This contains all configurations for the extension and for the plugins. The controls on the bottom, 1, 2, 3 and 4, are used to save or cancel the changes made.

3, Reset all changes is used to bring the extension to the default state. So all saved settings for all projects will be forgotten.

General Settings - authentication

Image


Please fill in details about server before using the extension (1) and (2). Once a new authentication a re-synch with the server will be made and analysis can be started. Tokens can be used, in that case leave password field empty and put token under the username field.

When connect at start is enabled, visual studio will connect to server automatically. Test connection will validate (3) and connect to server (4) will establish a connection.

dont forget to save after changing settings

On the main window the connection can also be established after the authentication is done.

Image

Editor options

Image

  1. Turns off editor integration
  2. In standalone mode, the external editor is used to open logs.

Other options

Image

  1. enable debug mode for the extension, when selected all exceptions found during will be logged in the Visual Studio Output window (VSSonarQubeOutput)

Setup the analysis environment

Ensure you have powershell 4.0 before running the configuration

Image

  1. Press download, this will install chocolatey and some additional code analysers like cppcheck.

If you are behind a proxy can download the wrapper from https://github.com/jmecsoftware/sonar-cxx-msbuild-tasks and then set manually those paths in the Wrapper Path. If you are behind proxy you might want to check also the same page for more details about the analysis tools.

Plugin Manager

Plugins are installed via the plugin manager.

Image

  1. Add or remove plugins. This works on the fly, does not require visual studio restart.
  2. List of available plugins
  3. Plugin information
  4. Plugin specific configuration. If a pluign provides additional settings they will show also in the extension properties.

Installing a plugin

  1. Press the + sign.

Image

  1. Locate the plugin you want to install and press open

Image

  1. Restart visual studio to ensure everything is working properly

Upgrading a plugin

  1. First uninstall the previous version of the plugin using the uninstall button and restart visual studio.
  2. Verify that the plugin no longer exists in the plugin manager.
  3. Follow the previous section to install the new.

License Manager

When available licenses can be configured here. Trial licenses might not be available Image

  1. Displays available licenses
  2. Generate user token to enable a license in server
  3. Refreshs available licenses

Roslyn Manager

Image This displays the locally available roslyn diagnostics and its rules. More can be configured using the controls.