diff --git a/tools/scripts/AksEdgeAzureSetup/AksEdgeAzureSetup.ps1 b/tools/scripts/AksEdgeAzureSetup/AksEdgeAzureSetup.ps1 index 0553fd2..153077e 100644 --- a/tools/scripts/AksEdgeAzureSetup/AksEdgeAzureSetup.ps1 +++ b/tools/scripts/AksEdgeAzureSetup/AksEdgeAzureSetup.ps1 @@ -23,7 +23,7 @@ New-Variable -Option Constant -ErrorAction SilentlyContinue -Name arcLocations - function Set-CLILoginExperience { - $currVersion = ((az version) | ConvertFrom-Json).'azure-cli' + $currVersion = ((az version -o json) | ConvertFrom-Json).'azure-cli' if($currVersion -eq '2.61.0') { Write-Host "Warning: Az CLI version 2.61.0 has known issues. Default to v1 login experience." -ForegroundColor Yellow @@ -35,7 +35,7 @@ function Set-CLILoginExperience function Test-AzVersions { #Function to check if the installed az versions are greater or equal to minVersions $retval = $true - $curVersion = (az version) | ConvertFrom-Json + $curVersion = (az version -o json) | ConvertFrom-Json if (-not $curVersion) { return $false } foreach ($item in $cliMinVersions.Keys ) { Write-Host " Checking $item minVersion $($cliMinVersions.$item).." -NoNewline