powershell-windows
Installation
SKILL.md
PowerShell — Windows Automation Mastery
Mandatory Pre-Flight Context Inspection
Before writing PowerShell .ps1 scripts or Windows automation commands, you MUST inspect:
- Object Pipeline vs String Parsing Rule (Section 23) → Operate directly on .NET object properties (
Get-Process | Stop-Process); ban string splitting/parsing - Mandatory Script Strict Mode Header (Section 43) → Always declare
$ErrorActionPreference = "Stop"andSet-StrictMode -Version Latestat top of automation scripts - Process-Scoped Execution Policy Bypass (Section 68) → Use process-level policy override (
powershell.exe -ExecutionPolicy Bypass -File ...); ban system-wideSet-ExecutionPolicy Unrestricted
Activation Boundaries
- Activate when: Operating in tasks requiring PowerShell and Windows environment mastery. Object-oriented piping, strict error handling (ErrorActionPreference), PSProviders, active directory querying, credential management, and execution policies. Use when automating Azure, Windows environments, or writing .ps1 scripts..
- DO NOT activate when: The task falls strictly outside powershell-windows domain or belongs to a different dedicated specialist.