-
Notifications
You must be signed in to change notification settings - Fork 591
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Consider adding static analysis #444
Comments
All good ideas but a |
Done! #448 |
#689 resolved the |
Moving to version |
Challenge accepted :) |
Codacy is free for open source and is quite capable. It also supports SonarQube's configuration format so it can be committed to source. We use it and are quite happy with it. Someone with administrative rights to this repository can set up analysis by logging in to Codacy and performing a few steps. If there's anything I can do to help, please holler! |
Infersharp may also be a low-hanging fruit worth implementing since it's available as a GitHub Action: - name: Run C# Code Analyzer
uses: microsoft/[email protected]
id: runcsharpcodeanalyzer
with:
binary-path: '<path to the binary directory containing .dlls and .pdbs>'
- name: C# Code Analyzer analysis results
run: echo "${{ steps.runcsharpcodeanalyzer.outputs.results }}" |
I think a good first step is looking at and figuring out which Roslyn analyzers to enable and which to set as warning and error. There are a bunch of new ones coming in .NET 5.0 as well. |
Please see #1269 |
There are a few analyzers provided by Microsoft: https://github.com/dotnet/roslyn-analyzers
There's also one from Sonar (https://www.nuget.org/packages/SonarAnalyzer.CSharp/) and their platform (https://www.sonarqube.org/).
There's also .editorconfig (https://docs.microsoft.com/en-us/visualstudio/ide/create-portable-custom-editor-options). This would enforce style on the code base and would prevent contributors to inadvertently make useless changes to the code.
The text was updated successfully, but these errors were encountered: