diff --git a/images/macos/software-report/SoftwareReport.Common.psm1 b/images/macos/software-report/SoftwareReport.Common.psm1 index 782b137f..8ed019f9 100644 --- a/images/macos/software-report/SoftwareReport.Common.psm1 +++ b/images/macos/software-report/SoftwareReport.Common.psm1 @@ -418,7 +418,7 @@ function Get-AppCenterCLIVersion { } function Get-AzureCLIVersion { - $azureCLIVersion = Run-Command "az -v" | Select-String "^azure-cli" | Take-Part -Part 1 + $azureCLIVersion = (az version | ConvertFrom-Json).'azure-cli' return "Azure CLI $azureCLIVersion" }