From asynkron-devtools
Runs C# static analysis, auto-fixes code issues, formats code, and detects unused code in .NET projects via the Roslynator CLI.
How this skill is triggered — by the user, by Claude, or both
Slash command
/asynkron-devtools:roslynator [solution or project path][solution or project path]The summary Claude sees in its skill listing — used to decide when to auto-load this skill
Check if roslynator is installed:
Check if roslynator is installed:
which roslynator
If not found, try running via dnx (no install needed, .NET 10+):
dnx Roslynator.DotNet.Cli [command] [options]
Or install globally:
dotnet tool install -g roslynator.dotnet.cli
Roslynator is a set of code analysis tools for C# powered by Roslyn. It provides 500+ analyzers, refactorings, and code fixes. The CLI tool can analyze, fix, and format entire solutions from the command line — no IDE needed.
The CLI itself contains no analyzers — they come from NuGet packages referenced in your project (e.g. Roslynator.Analyzers) or via --analyzer-assemblies.
Fix all diagnostics in a solution:
roslynator fix MySolution.sln
Fix all diagnostics in a project:
roslynator fix MyProject.csproj
Analyze without fixing (report only):
roslynator analyze MySolution.sln
Format code:
roslynator format MySolution.sln
Find unused code (dead code detection):
roslynator find-unused MySolution.sln
List symbols:
roslynator list-symbols MySolution.sln
Count lines of code:
roslynator lloc MySolution.sln
| Command | Purpose |
|---|---|
fix | Auto-fix diagnostics in project/solution |
analyze | Report diagnostics without fixing |
format | Format whitespace |
find-unused | Find unused declarations (dead code) |
list-symbols | List types, members, and symbols |
lloc | Count logical lines of code |
loc | Count physical lines of code |
spellcheck | Check spelling in comments and strings |
| Flag | Purpose |
|---|---|
--projects <name> | Only process named projects |
--ignored-projects <name> | Skip specific projects |
--include <glob> | Include matching files/folders |
--exclude <glob> | Exclude matching files/folders |
-v, --verbosity <level> | Output level: quiet, minimal, normal, detailed, diagnostic |
-p, --properties <NAME=VALUE> | MSBuild properties (e.g. Configuration=Release) |
-m, --msbuild-path <dir> | Path to MSBuild directory |
--language <lang> | Language: cs or vb |
-g, --include-generated-code | Include generated code |
--file-log <path> | Write output to file |
-h, --help | Show help |
| Flag | Purpose |
|---|---|
-a, --analyzer-assemblies <path> | Paths to additional analyzer assemblies |
--supported-diagnostics <id> | Report only these diagnostic IDs |
--ignored-diagnostics <id> | Skip these diagnostic IDs |
--severity-level <level> | Minimum severity: hidden, info, warning, error |
--ignore-compiler-diagnostics | Hide compiler messages |
-o, --output <path> | Save diagnostics to file |
--output-format | Report format: xml or gitlab |
--execution-time | Measure analyzer performance |
Roslynator is configured via .editorconfig in your project:
Set severity for all Roslynator analyzers:
[*.cs]
dotnet_analyzer_diagnostic.category-roslynator.severity = warning
Enable/disable specific analyzers:
[*.cs]
dotnet_diagnostic.RCS1001.severity = none # Disable specific rule
dotnet_diagnostic.RCS1036.severity = error # Upgrade to error
Enable/disable refactorings:
[*.cs]
roslynator_refactoring.add_braces.enabled = false
| Code | Meaning |
|---|---|
0 | Success — no diagnostics found or all fixed |
1 | Diagnostics found or not all fixed |
2 | Error or execution canceled |
Roslynator is used in the /pre-pr quality gate as the first step:
roslynator fix — auto-fix code issuesdotnet build — verify compilationdotnet test — run testsquickdup — check for duplicationdotnet format — format coderoslynator analyze — it needs compiled outputroslynator fix for auto-fixing, roslynator analyze for CI reporting--severity-level warning to skip info/hidden diagnostics in CI--ignored-diagnostics to suppress known false positivesroslynator find-unused periodically to catch dead code.editorconfig rather than via CLI flags for consistency across teamnpx claudepluginhub asynkron/asynkron-skills --plugin asynkron-devtoolsAdds Roslynator and Meziantou analyzers, creates a comprehensive .editorconfig with 80+ diagnostic rules for enforcing strict .NET/C# coding standards.
Patterns for detecting and managing code smells and technical debt in .NET applications. Run Slopwatch CLI to detect LLM reward hacking, disabled tests, suppressed warnings, empty catches, and other shortcuts. Use when identifying code smells, running quality gates in CI/CD, or validating LLM-generated code changes.
Runs a systematic 7-step cleanup pipeline for .NET projects: formatting, unused usings, analyzer warnings, dead code removal, TODO resolution, sealed class audit, and CancellationToken propagation. Verifies after each step with build and test.