SonarSource/sonarlint-omnisharp

Modify rules configuration service to accept a list of active rules

Closed this issue · 0 comments

Description

Modify the contract for the rules configuration service so the caller only has to supply the list of rules to be executed and their parameters. Any rules that are not listed should be disabled.

Implementation notes

There are a number of rules that should not be run in the IDE and should not appear in the rule configuration UI i.e. security hotspot rules. However, these rules are enabled by default, so it is necessary to explicitly disable them before running the analysis.

This change simplifies things on the Java/UI side. The Java/UI side already does not display security hotspot rules in the UI.
The .NET extension side already knows all of the rules that are exposed by the analyzers.
Simply disabling any rules that are not explicitly enabled by the Java/UI side will have the effect of disabling any hotspot rules.