PowerShell pitfall checker
Give it a Windows script. Get operator, quoting and error handling mistakes caught and fixed.
PowerShell pitfall checker is a free AI skill for the job "Test and fix code". Give the instructions to an AI assistant that supports the required files and tools, then review its output.
Free · No account · CC BY 4.0 licence · Made by sickn33 · Level: beginner · Thinking: low
Made by sickn33. See the original on GitHub; we copied it as it is, with its licence.
What it does
Catch the Windows PowerShell mistakes that make scripts fail for no clear reason, and get the corrected script back. The skill checks for known traps. Logical operators like -and and -or need each command wrapped in brackets. Emoji and fancy symbols break output, so it swaps them for plain tags like [OK] and [!]. It reviews null checks, quoting, error handling and path handling, and rewrites any line that is wrong. You paste your script and get a list of what was found plus a fixed version. It is built for Windows PowerShell.
You give it
- Your PowerShell script
- Error message (optional)
- Windows or PowerShell version (optional)
You get
- List of mistakes found
- Corrected script
- Plain explanation for each fix
Use it when
- A script runs on your machine but errors on a colleague's.
- An if statement with -or behaves strangely.
- Your output shows garbled characters.
- You want a quick review before sharing a script.
How to use it
- Add it to your AI once: download it and add the folder to Claude, ChatGPT or Codex as a skill.
- Ask for the job in your own words. Your AI opens the skill when it fits.
- It works best when your AI can run PowerShell.