Scanning Powershell Compatibility

Detect Windows PowerShell 5.1 → 7.x compatibility blockers across a tree of .ps1/.psm1/.psd1 files. Two parts: generate and validate a PSScriptAnalyzer compatibility profile for the target host (the primary detector, covering removed commands/parameters/types), then run a small parser-driven catalog as a sidecar for what PSScriptAnalyzer is structurally blind to — encoding and other behavioral changes, parameter values, type accelerators, module availability, COM, and deprecated-but-present cmdlets. Produces scan-findings.csv keyed by rule id, which seeds the assessment, the plan, and the execution re-scan gate. Use during the powershell-5.1-to-7-upgrade scenario, or any time you need a reproducible inventory of PowerShell compatibility blockers. DO NOT USE FOR: scanning C#/.NET code, PSScriptAnalyzer style rules, or verifying that a fix works (that is the validation ladder's job). INVOKES: scripts/New-PSSACompatibilityProfile.ps1, scripts/Get-PSCompatibilityScan.ps1.

Microsoft 9175b13 5 files · 196.4 KB Updated 2.7k repo stars

File contents

microsoft/upgrade-agent-plugins/tree/main/plugins/upgrade-agent/upgrade/dotnet/skills/lazy/pwsh/scanning-powershell-compatibility commit 9175b1313f

Frequently asked questions

npx skillmds@latest add microsoft/scanning-powershell-compatibility