lint-dotnet
Lint .NET architecture rules
.NET projects often have inconsistent build patterns that cause maintenance problems. This skill runs an automated linter to check for MSBuild violations and Central Package Management issues before they cause problems in your codebase.
Baixar o ZIP da skill
Upload no Claude
Vá em Configurações → Capacidades → Skills → Upload skill
Ative e comece a usar
Testar
A utilizar "lint-dotnet". /lint-dotnet
Resultado esperado:
- CLEAN: All rules passed
- No violations found. Safe to proceed.
- Directory.Packages.props uses $(VariableName) format
- Version.props imported only in allowed files
A utilizar "lint-dotnet". /lint-dotnet
Resultado esperado:
- RULE_A violation detected
- Directory.Packages.props line 5: Hardcoded Version="1.2.3" found
- Fix: Replace with $(PackageNameVersion) and define in Version.props
- RULE_G violation detected
- MyApp.csproj line 12: Inline Version attribute on PackageReference
- Fix: Remove Version attr and add to Directory.Packages.props
Auditoria de Segurança
SeguroAll 24 static findings are FALSE POSITIVES. The analyzer misidentified markdown documentation examples as executable code and cryptographic metadata hashes as weak algorithms. This is a documentation-only skill that references an external bash script for linting .NET architecture patterns. No actual execution, network calls, or file access occurs within the skill files.
Fatores de risco
⚙️ Comandos externos (17)
🌐 Acesso à rede (1)
Pontuação de qualidade
O Que Você Pode Construir
Validate project structure
Check that your .NET project follows established architecture patterns before committing code changes
Enforce build standards
Run as part of CI pipelines to ensure all projects maintain consistent build patterns across teams
Review architecture compliance
Audit repositories for consistent use of Central Package Management and proper version handling conventions
Tente Estes Prompts
/lint-dotnet
/lint-dotnet to check for any MSBuild violations in this project
/lint-dotnet and explain how to fix the violations that are reported
/lint-dotnet to validate that all .NET architecture rules are satisfied before I commit
Melhores Práticas
- Run /lint-dotnet before committing .NET projects to catch architecture violations early in development
- Use Central Package Management for all version references to ensure consistency across solutions
- Keep Version.props as a symlink in consumer repositories, never copy the file directly
Evitar
- Hardcoding versions like Version="1.2.3" directly in Directory.Packages.props instead of using variables
- Importing Version.props from arbitrary .props files outside the allowed list
- Copying Version.props instead of symlinking it in downstream repositories