A cross-platform PowerShell utility module for creating resumable, step-by-step scripts with automatic state persistence.
Install-Module -Name Stepper -Scope CurrentUser -ForceCreate a .ps1 script with New-Step blocks:
#Requires -Modules Stepper # documents the dependency; Stepper enforces this
[CmdletBinding()] # required for error propagation and -Verbose support
param()
New-Step 'Download Files' {
Write-Host "Downloading files..."
# your code here
}
New-Step 'Process Data' {
Write-Host "Processing data..."
# your code here
}
New-Step 'Upload Results' {
Write-Host "Uploading results..."
# your code here
}
Stop-Stepper # removes the state file on successful completionIf the script fails inside a New-Step block, the next run resumes at the step that failed. All previously completed steps are skipped!
Test.ps1.mp4
- How It Works — execution lifecycle, resume logic, verbose output, non-interactive mode
- Named Steps — step names,
$Stepper.StepName, resume prompt formats - Data Persistence —
$Stepperhashtable, state file schema - Unmanaged Code — detection,
#region Stepper ignore, interactive resolution - API Reference —
New-Step,Stop-Stepper, error handling - Examples
- Troubleshooting
MIT License w/Commons Clause - see LICENSE file for details.
Made with 💜 by Jake Hildreth
