summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorThomas Powell <powell@progress.com>2022-10-28 13:16:49 -0400
committerThomas Powell <powell@progress.com>2022-10-28 13:16:49 -0400
commit6b97d62401a9f5fc4fbe1805b5b11cbf35776630 (patch)
tree952329965d535f69295b6e8b98ba61349eb6bf13
parentb00e475316c87aac92bc63aa79eb31c4f682d9e7 (diff)
downloadchef-6b97d62401a9f5fc4fbe1805b5b11cbf35776630.tar.gz
try/catch fix
Signed-off-by: Thomas Powell <powell@progress.com>
-rw-r--r--habitat/plan.ps12
1 files changed, 1 insertions, 1 deletions
diff --git a/habitat/plan.ps1 b/habitat/plan.ps1
index 83ca0e78cb..fe3693e6e0 100644
--- a/habitat/plan.ps1
+++ b/habitat/plan.ps1
@@ -57,7 +57,7 @@ function Invoke-Download() {
Write-Host "--- :construction: Verifying Git is Installed"
try {
- $source = Get-Command -Name Git -Verbose
+ $source = Get-Command -Name Git -Verbose -ErrorAction Stop
Write-Host "Which version of Git is installed? - " $source.version
} catch {