Skip to content

Commit

Permalink
Update
Browse files Browse the repository at this point in the history
  • Loading branch information
Jefajers authored Mar 20, 2024
1 parent fcc716c commit 006e08f
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions src/internal/functions/Assert-AzOpsJqDependency.ps1
Original file line number Diff line number Diff line change
Expand Up @@ -19,13 +19,13 @@

process {
Write-AzOpsMessage -LogLevel InternalComment -LogString 'Assert-AzOpsJqDependency.Validating'

$minVersion = New-Object System.Version("1.6")
$result = (Invoke-AzOpsNativeCommand -ScriptBlock { jq --version } -IgnoreExitcode)
$installed = $result -as [bool]

if ($installed) {
[double]$version = ($result).Split("-")[1]
if ($version -ge 1.6) {
$version = New-Object System.Version(($result).Split("-")[1])
if ($version -ge $minVersion) {
Write-AzOpsMessage -LogLevel InternalComment -LogString 'Assert-AzOpsJqDependency.Success'
return
}
Expand Down

0 comments on commit 006e08f

Please sign in to comment.