This commit is contained in:
2026-01-31 22:10:45 -05:00
parent 6d26cbbb35
commit 39962ec491

View File

@@ -139,10 +139,19 @@ $chunks = @(
foreach ($c in $chunks) {
$content = Import-SamyChunk -Url $c.Url -Name $c.Name
try {
$content = Import-SamyChunk -Url $c.Url -Name $c.Name -ErrorAction Stop
. ([ScriptBlock]::Create($content))
Write-Host "[Success] Loaded: $($c.Name)" -ForegroundColor Green
Write-Host "[Success] $($c.Name)" -ForegroundColor Green
}
catch {
$msg = $_.Exception.Message
if ([string]::IsNullOrWhiteSpace($msg)) { $msg = "$_" }
Write-Host "[Failed] $($c.Name): $msg" -ForegroundColor Red
throw # or continue
}
}
if (-not (Get-Command Invoke-ScriptAutomationMonkey -ErrorAction SilentlyContinue)) {