PSKoans
Make failing Pester tests pass to learn PowerShell scripting step by step
Run Show-Karma and the module names the next assertion that fails and the file it lives in. Show-Karma -Contemplate opens the koan folder in your editor, and the opening file, AboutAssertions, asks you to replace blanks such as $____ and __ so that lines like __ + 5 | Should -Be 10 hold true. Save, run Show-Karma again, and the next one is waiting.
Free · No login · Terminal · Beginner

About PSKoans
The library is split into topic files across folders. Introduction covers assertions, booleans, numbers, strings, binary, Get-Member and cmdlet verbs. Foundations moves through arrays, hashtables, comparison, conditionals, loops and pipelines, and functions and script blocks. Two Cmdlets folders deal with Where-Object, Group-Object, Compare-Object and the CSV and Out cmdlets, and Constructs and Patterns reaches classes, enums, splatting, error handling, regular expressions, XML and StringBuilder. Two katas ask you to process strings and sort characters, and further folders exercise dbatools against mocked SQL Server results and Active Directory filtering.
Rain (vexx32 on GitHub) created the project, which now lives under PowerShellOrg. The format is the one Rustlings uses for Rust. UnderTheWire also runs on PowerShell, but as an SSH wargame where you hunt for passwords.
Questions about PSKoans
What do I need installed before the PowerShell koans will run?
How does a koan check whether my answer is right?
Made this game? Claim it →

Tips and discussion
No tips yet.
Sign in to share a tip.