PSScriptAnalyzer.
Check PowerShell scripts and modules
Validate cmdlet usage, parameter conventions and selected reliability rules. Run the same settings against scripts and modules before publishing.
PowerShell
Community rubric · v1
The evidence
One point for each verified check. Unknown means we still need evidence. Contrary evidence records an observed result that goes against the criterion.
Latest evidence review ·
Definition
UnknownNo reviewed evidence is recorded for this dimension.
Can two readers identify the same obligation? Contribute evidence ↗
Measurement
VerifiedInvoke-ScriptAnalyzer emits one DiagnosticRecord per rule violation; -SuppressedOnly returns a different record type.
Conformance
UnknownNo reviewed evidence is recorded for this dimension.
What would demonstrate a violation? Contribute evidence ↗
CI enforcement
VerifiedThe -EnableExit flag writes a process exit status derived from diagnostics, a mode Microsoft explicitly recommends for CI.
Getting started
UnknownNo reviewed evidence is recorded for this dimension.
Can a newcomer complete a first run? Contribute evidence ↗
Real-world adoption
VerifiedCodeRabbit checks .ps1 scripts, .psm1 modules and .psd1 manifests with PSScriptAnalyzer in its review integration.
Agent guidance
UnknownNo reviewed evidence is recorded for this dimension.
Can an agent act on a specific finding? Contribute evidence ↗
Agent portability
UnknownNo reviewed evidence is recorded for this dimension.
Does the practice work in two agent harnesses? Contribute evidence ↗
Use this standard
Run the check with the tool installed and configured for your project.
Invoke-ScriptAnalyzer -Path . -Recurse
Agent prompt
Use PSScriptAnalyzer in this repository to meet this standard: Check PowerShell scripts and modules. Validate cmdlet usage, parameter conventions and selected reliability rules. Run the same settings against scripts and modules before publishing. Inspect the repository configuration, record the baseline and exact reproduction steps, then add the smallest repeatable check that detects a regression.