dotnet
無料Primary router skill for broad .NET work. Classify the repo by app model and cross-cutting concern first, then switch to the narrowest matching .NET skill instead of staying at a generic layer.
日本語の概要は準備中です。原文の説明を表示しています。
Use the free built-in .NET SDK analyzers and analysis levels with gradual Roslyn warning promotion. Use when a .NET repo needs first-party code analysis, `EnableNETAnalyzers`, `AnalysisLevel`, or warning-as-error policy wired into build and CI.
インストールする前に、エージェントに与えられる指示の中身を確認できます。
AnalysisLevel or AnalysisMode guidanceAGENTS.mdDirectory.Build.propsNon-negotiable. Violating these undermines the user's explicit intent.
TreatWarningsAsErrors or WarningsAsErrors if the project has set them. Do not comment them out, set to false, wrap in a condition, or add <TreatWarningsAsErrors>false</TreatWarningsAsErrors> to make the build pass.<NoWarn> or #pragma warning disable for warnings the user chose to treat as errors, unless the user explicitly approves the suppression..editorconfig (e.g. error to warning or none) to make a build succeed.flowchart TD
A[Start] --> B{New or legacy project?}
B -->|New| C[TreatWarningsAsErrors=true immediately]
B -->|Legacy| D[dotnet build, count warnings by ID]
D --> E{"< 30 warnings?"}
E -->|Yes| F[Fix all, then enable TreatWarningsAsErrors]
E -->|No| G[Report counts to user, ask which batch first]
G --> H[Add selected IDs to WarningsAsErrors]
H --> I[Fix that batch, verify build]
I --> J{More batches?}
J -->|Yes| G
J -->|No| F
C --> K[Set AnalysisLevel latest-recommended]
F --> K
K --> L[Promote security CA3xxx/CA5xxx to error in .editorconfig]
L --> M[Validate: build + CI green]
EnableNETAnalyzers, AnalysisLevel, AnalysisMode in Directory.Build.props..editorconfig.dotnet build is the analyzer gate in CI.Set these in Directory.Build.props immediately:
TreatWarningsAsErrors = trueAnalysisLevel = latest-recommended.editorconfigFix all warnings before merging.
Blanket TreatWarningsAsErrors on a legacy codebase produces hundreds/thousands of errors. An agent cannot fix them all at once — context floods, fix quality drops. Promote in batches.
Mechanical fixes, lowest effort:
Add to WarningsAsErrors: CS8019;CS0219;CS0168. Fix all, then Phase 2.
Ask: "Which categories next — Nullability, Performance, or Reliability?" Add selected IDs to WarningsAsErrors, fix, repeat.
Set in .editorconfig regardless of project maturity:
[*.cs]
dotnet_analyzer_diagnostic.category-Security.severity = error
Covers CA3001 (SQL injection), CA3002 (XSS), CA3003 (path injection), CA3075 (insecure DTD), CA5350/CA5351 (weak crypto), CA5394 (insecure randomness).
Once all batches pass, transition to:
<TreatWarningsAsErrors>true</TreatWarningsAsErrors>
<WarningsNotAsErrors>CA1707</WarningsNotAsErrors> <!-- explicit exceptions only -->
dotnet build, count warnings by ID.WarningsAsErrors.Never skip the ask step. The user decides the pace.
dotnet --inforg -n "EnableNETAnalyzers|AnalysisLevel|AnalysisMode|TreatWarningsAsErrors|WarningsAsErrors" -g '*.csproj' -g 'Directory.Build.*' .dotnet build SOLUTION_OR_PROJECT 2>&1 — count warnings by IDEnableNETAnalyzers, AnalysisLevel, AnalysisMode in MSBuild config..editorconfig.dotnet build, return status: configured or status: improved.status: not_applicable.TreatWarningsAsErrors, WarningsAsErrors, or severity settings removed/weakened without user approvalstatus: not_applicable.status: complete | clean | improved | configured | not_applicable | blockedplan: concise plan and current stepactions_taken: concrete changesvalidation_skills: final skills run or skipped with reasonsverification: commands, checks, or review evidenceremaining: unresolved items or nonereferences/rules.mdreferences/config.mdreferences/code-analysis.mdまだレビューはありません。使ってみた感想をお寄せください。
概要と使いどころ
Primary router skill for broad .NET work. Classify the repo by app model and cross-cutting concern first, then switch to the narrowest matching .NET skill instead of staying at a generic layer.
日本語の概要は準備中です。原文の説明を表示しています。
Use a repo-root `.editorconfig` to configure free .NET analyzer and style rules. Use when a .NET repo needs rule severity, code-style options, section layout, or analyzer ownership made explicit. Nested `.editorconfig` files are allowed when they serve a clear subtree-specific purpose.
日本語の概要は準備中です。原文の説明を表示しています。
Build, debug, modernize, or review ASP.NET Core applications with correct hosting, middleware, security, configuration, logging, and deployment patterns on current .NET.
日本語の概要は準備中です。原文の説明を表示しています。
Use Biome in .NET repositories that ship Node-based frontend assets and want a fast combined formatter-linter-import organizer for JavaScript, TypeScript, CSS, JSON, GraphQL, or HTML. Use when a repo prefers a modern all-in-one CLI over a larger ESLint plus Prettier style stack.
日本語の概要は準備中です。原文の説明を表示しています。
Build and review Blazor applications across server, WebAssembly, web app, and hybrid scenarios with correct component design, state flow, rendering, and hosting choices.
日本語の概要は準備中です。原文の説明を表示しています。
Use the open-source free `CSharpier` formatter for C# and XML. Use when a .NET repo intentionally wants one opinionated formatter instead of a highly configurable `dotnet format`-driven style model.
日本語の概要は準備中です。原文の説明を表示しています。