- Operating system: Windows, Mac OS
- IDE name and flavor/env: Visual Studio Pro 2022, JetBrains Rider 2024.3.2+
The organization I work for uses the multirepo approach to source control and to my regret it will not change in the observable future. We have around 310 repositories at the moment, of which somewhere between 50-75% are using SonarCloud for static code analysis.
Our software developers are actively using Visual Studio 2022 and JetBrains Rider; VS being a formal standard, and Rider being a superior personal-preference permitted IDE.
Question: How to configure SonarLint/SonarCloud’s settings for the connected mode to be source-controlled and IDE-agnostic?
I thought that we could just keep .sonarlint/*.json
in the root of the repository and have the IDE-specific plugins read the configuration from there. However, from my experience, only the Visual Studio’s plugin respects that config directory, while the Rider IDE ignores it altogether and shows the popup notification inviting to configure the Connected mode.
I saw two topics related to this:
- SonarLint Connected Mode for SonarCloud setup for VS Code, VS and Rider - #5 by JenteVets
- SonarLint for Visual Studio v7.0 - Connected mode settings are moving to a new place - #2
Hopefully, these threads are outdated, and this has changed by now. Otherwise, I agree with @ TheNybbler’s comment on the latter one that the direction away from a git-controlled config is a backwards step from the user perspective. Please consider what ESLint does for its configuration and mimic that behavior.
This way it would be:
- IDE-agnostic (no maintenance burden) and
- Zero-action for developer on repository checkout — we can’t afford configuring each time we checkout a new repo, as they are too many.