Skip to content
C

crap-score

Calculates CRAP (Change Risk Anti-Patterns) for a named .NET method, class

by dotnetFree

#4295in AI Skills
0In stores

Description

CRAP Score is a .NET agent skill from the dotnet/skills repository that calculates Change Risk Anti-Patterns scores for a named method, clas…

Highlights

  • CRAP score for a method, class or file
  • Combines cyclomatic complexity and coverage
  • Highlights complex, undertested code
  • Scoped risk checks before refactoring

Ratings & Reviews

No ratings yet

Be the first to rate crap-score.

People also visit

C

coverage-analysis

Activation requires either supplied .NET coverage reports/percentages/line

AI Skills
Get
H

health-check

Multi-dimensional health assessment for .NET projects with letter grades

AI Skills
Get
H

hook-complexity-monitor

Monitor code complexity and maintain code quality

AI Skills
Get
C

code-review

MCP-powered multi-dimensional code review for .NET projects

AI Skills
Get
D

dotnet-best-practices

Validate .NET/C# code against comprehensive best practices for your solution

AI Skills
Get
A

analyzing-dotnet-performance

Scans .NET code for ~50 performance anti-patterns across async, memory, strings

AI Skills
Get

crap-score FAQ

What is a CRAP score?

Change Risk Anti-Patterns: comp(m)^2 x (1 - cov(m))^3 + comp(m), where comp is cyclomatic complexity and cov is coverage from 0 to 1. Higher scores mean complex code with little test coverage.

What scope can it analyze?

A named .NET method, class or file.

When should I use it?

When you explicitly want a CRAP calculation or a coverage-and-complexity risk check for a specific part of your code.

How do I add this skill to my agent?

Use the skills CLI: `npx skills add https://github.com/dotnet/skills --skill crap-score`. This pulls the skill from dotnet/skills on GitHub.

Has the skill been security audited?

Yes. Results shown on skills.sh: Gen Agent Trust Hub: Pass, Socket: Pass, Snyk: Pass.

What are the best crap-score alternatives?

Popular alternatives to crap-score include coverage-analysis, health-check and hook-complexity-monitor. See all crap-score alternatives

Developer Stuff

Badges