Meziantou.Analyzer
Trigger On
- the repo uses or wants
Meziantou.Analyzer
- the team wants one analyzer pack that covers design, usage, security, performance, and style
Value
- produce a concrete project delta: code, docs, config, tests, CI, or review artifact
- reduce ambiguity through explicit planning, verification, and final validation skills
- leave reusable project context so future tasks are faster and safer
Do Not Use For
- repos that already enforce an overlapping analyzer baseline and do not want extra diagnostics
- formatting-only work
Inputs
- the nearest
AGENTS.md
- current analyzer packages
.editorconfig
Quick Start
- Read the nearest
AGENTS.md and confirm scope and constraints.
- Run this skill's
Workflow through the Ralph Loop until outcomes are acceptable.
- Return the
Required Result Format with concrete artifacts and verification evidence.
Workflow
- Add
Meziantou.Analyzer when the repo wants broader rules than the SDK baseline.
- Keep rule severity in the repo-root
.editorconfig.
- Review overlaps with SDK analyzers and Roslynator before mass-enabling everything as errors.
Bootstrap When Missing
If Meziantou.Analyzer is not configured yet:
- Detect current state:
rg -n "Meziantou\\.Analyzer" -g '*.csproj' .
- Add the package to the intended scope (project-level or shared props strategy):
dotnet add PROJECT.csproj package Meziantou.Analyzer
- Set severity in root
.editorconfig for the enabled MAxxxx rules.
- Keep overlap with SDK analyzers and Roslynator explicit to avoid duplicate noise.
- Run
dotnet build SOLUTION_OR_PROJECT and return status: configured or status: improved.
- If the repo intentionally keeps a smaller analyzer surface, return
status: not_applicable.
Deliver
- explicit Meziantou package setup
- repo-owned severity and warning policy
Validate
- the added rules are understood by the team
- CI runs stay actionable instead of noisy
Ralph Loop
Use the Ralph Loop for every task, including docs, architecture, testing, and tooling work.
- Plan first (mandatory):
- analyze current state
- define target outcome, constraints, and risks
- write a detailed execution plan
- list final validation skills to run at the end, with order and reason
- Execute one planned step and produce a concrete delta.
- Review the result and capture findings with actionable next fixes.
- Apply fixes in small batches and rerun the relevant checks or review steps.
- Update the plan after each iteration.
- Repeat until outcomes are acceptable or only explicit exceptions remain.
- If a dependency is missing, bootstrap it or return
status: not_applicable with explicit reason and fallback path.
Required Result Format
status: complete | clean | improved | configured | not_applicable | blocked
plan: concise plan and current iteration step
actions_taken: concrete changes made
validation_skills: final skills run, or skipped with reasons
verification: commands, checks, or review evidence summary
remaining: top unresolved items or none
For setup-only requests with no execution, return status: configured and exact next commands.
Load References
references/meziantou-analyzer.md
references/rules.md
references/config.md
Example Requests
- "Add Meziantou analyzers to the repo."
- "Use Meziantou for extra quality and security checks."
1---
2name: dotnet-meziantou-analyzer
3version: "1.0.0"
4category: "Code Quality"
5description: "Use the open-source free `Meziantou.Analyzer` package for design, usage, security, performance, and style rules in .NET. Use when a repo wants broader analyzer coverage with a single NuGet package."
6compatibility: "Requires a .NET SDK-based repository; respects the repo's `AGENTS.md` commands first."
7metadata:
8 source: https://skillmd.com/skills/aibot88/dotnet-meziantou-analyzer
9---
10
11# Meziantou.Analyzer
12
13## Trigger On
14
15- the repo uses or wants `Meziantou.Analyzer`
16- the team wants one analyzer pack that covers design, usage, security, performance, and style
17
18## Value
19
20- produce a concrete project delta: code, docs, config, tests, CI, or review artifact
21- reduce ambiguity through explicit planning, verification, and final validation skills
22- leave reusable project context so future tasks are faster and safer
23
24## Do Not Use For
25
26- repos that already enforce an overlapping analyzer baseline and do not want extra diagnostics
27- formatting-only work
28
29## Inputs
30
31- the nearest `AGENTS.md`
32- current analyzer packages
33- `.editorconfig`
34
35## Quick Start
36
371. Read the nearest `AGENTS.md` and confirm scope and constraints.
382. Run this skill's `Workflow` through the `Ralph Loop` until outcomes are acceptable.
393. Return the `Required Result Format` with concrete artifacts and verification evidence.
40
41## Workflow
42
431. Add `Meziantou.Analyzer` when the repo wants broader rules than the SDK baseline.
442. Keep rule severity in the repo-root `.editorconfig`.
453. Review overlaps with SDK analyzers and Roslynator before mass-enabling everything as errors.
46
47## Bootstrap When Missing
48
49If `Meziantou.Analyzer` is not configured yet:
50
511. Detect current state:
52 - `rg -n "Meziantou\\.Analyzer" -g '*.csproj' .`
532. Add the package to the intended scope (project-level or shared props strategy):
54 - `dotnet add PROJECT.csproj package Meziantou.Analyzer`
553. Set severity in root `.editorconfig` for the enabled `MAxxxx` rules.
564. Keep overlap with SDK analyzers and Roslynator explicit to avoid duplicate noise.
575. Run `dotnet build SOLUTION_OR_PROJECT` and return `status: configured` or `status: improved`.
586. If the repo intentionally keeps a smaller analyzer surface, return `status: not_applicable`.
59
60
61## Deliver
62
63- explicit Meziantou package setup
64- repo-owned severity and warning policy
65
66## Validate
67
68- the added rules are understood by the team
69- CI runs stay actionable instead of noisy
70
71## Ralph Loop
72
73Use the Ralph Loop for every task, including docs, architecture, testing, and tooling work.
74
751. Plan first (mandatory):
76 - analyze current state
77 - define target outcome, constraints, and risks
78 - write a detailed execution plan
79 - list final validation skills to run at the end, with order and reason
802. Execute one planned step and produce a concrete delta.
813. Review the result and capture findings with actionable next fixes.
824. Apply fixes in small batches and rerun the relevant checks or review steps.
835. Update the plan after each iteration.
846. Repeat until outcomes are acceptable or only explicit exceptions remain.
857. If a dependency is missing, bootstrap it or return `status: not_applicable` with explicit reason and fallback path.
86
87### Required Result Format
88
89- `status`: `complete` | `clean` | `improved` | `configured` | `not_applicable` | `blocked`
90- `plan`: concise plan and current iteration step
91- `actions_taken`: concrete changes made
92- `validation_skills`: final skills run, or skipped with reasons
93- `verification`: commands, checks, or review evidence summary
94- `remaining`: top unresolved items or `none`
95
96For setup-only requests with no execution, return `status: configured` and exact next commands.
97
98## Load References
99
100- `references/meziantou-analyzer.md`
101- `references/rules.md`
102- `references/config.md`
103
104## Example Requests
105
106- "Add Meziantou analyzers to the repo."
107- "Use Meziantou for extra quality and security checks."