From eb1c2e2c5e89eaedd6bcc7002dfe3ebf79fd2804 Mon Sep 17 00:00:00 2001 From: Evan Simkowitz Date: Wed, 23 Oct 2024 11:09:50 -0700 Subject: [PATCH] Add extra check to make sure tag isn't beta --- wave/update.ps1 | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/wave/update.ps1 b/wave/update.ps1 index 9e5447c..b9aaa21 100644 --- a/wave/update.ps1 +++ b/wave/update.ps1 @@ -17,11 +17,11 @@ function global:au_SearchReplace { function global:au_GetLatest { $Releases = "https://api.github.com/repos/wavetermdev/waveterm/releases/latest" $PageSource = Invoke-RestMethod -Uri $Releases - - if ($PageSource.tag_name -match 'v([\d.-]+)') { + Write-Host "tag_name=$($PageSource.tag_name)" + if ($PageSource.tag_name -match 'v([\d.]+)(-beta)?' -and 3 -gt $Matches.Count ) { $Version = $Matches[1] } else { - throw "Unable to grab tag name" + throw "Tag name does not match regex or is beta" } Write-Host "newversion=$($Version)"