Skip to content

Instantly share code, notes, and snippets.

View toddboyd's full-sized avatar

Todd Boyd toddboyd

View GitHub Profile
@toddboyd
toddboyd / run-apex-script.ps1
Created June 15, 2021 21:21
Run Apex PowerShell Script
# Run apex script
Write-Host -ForegroundColor green "Running apex script..."
& sfdx force:apex:execute -u $orgName -f [apex script]
if ($LASTEXITCODE -ne 0) {
exit 1
}
Write-Host ""