integrated-application-development / delphilint

Delphi IDE package providing on-the-fly code analysis and linting, powered by SonarDelphi
GNU Lesser General Public License v3.0
79 stars 9 forks source link

Support standalone mode rule configuration #37

Closed fourls closed 3 months ago

fourls commented 3 months ago

This PR adds a new user-level configuration setting to configure which rules are applied in standalone mode:

image

By default, DelphiLint is configured to use SonarDelphi's default ruleset (the Sonar way profile), preserving existing behaviour. Users can opt-in to configure their own ruleset, at which point they can enable or disable which rules they like. Under the hood, only disabled rules are stored, meaning that any new rules that appear as a result of a SonarDelphi upgrade will be automatically enabled.

As tends to happen with these sorts of paradigm-shift changes, this PR also includes a few collateral improvements:

Fixes #16

fourls commented 3 months ago

Implemented compatibility with the new features in the VS Code companion - while you can't customise the rules from within VSCode, it will honour the disabled rules configuration.