feat: add reset script to module 1

This commit is contained in:
Bjarke Sporring
2026-01-04 15:26:12 +01:00
parent 4a47d8b36e
commit acacd83084

View File

@@ -0,0 +1,29 @@
#!/usr/bin/env pwsh
<#
.SYNOPSIS
Resets the Module 01 challenge environment.
.DESCRIPTION
Removes the existing challenge directory and runs setup.ps1 to create a fresh challenge.
This is useful if you want to start over from scratch.
#>
Write-Host "Resetting Module 01: Git Basics Challenge..." -ForegroundColor Cyan
Write-Host ""
# Remove existing challenge directory if it exists
if (Test-Path "challenge") {
Write-Host "Removing existing challenge directory..." -ForegroundColor Yellow
Remove-Item -Path "challenge" -Recurse -Force
Write-Host "[SUCCESS] Challenge directory removed" -ForegroundColor Green
} else {
Write-Host "[INFO] No existing challenge directory found" -ForegroundColor Gray
}
Write-Host ""
Write-Host "Running setup script..." -ForegroundColor Cyan
Write-Host ""
# Run the setup script
& "$PSScriptRoot/setup.ps1"