Skip to content

Commit

Permalink
fix
Browse files Browse the repository at this point in the history
  • Loading branch information
ernestl committed Nov 22, 2024
1 parent 5156d7a commit e0b5ec4
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions .github/workflows/go-channels.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -40,9 +40,9 @@ jobs:
channel=$1
version=""
# Retrieve go version for valid channel format
if [[ "$channel" =~ ^[0-9]+\.[0-9]+/(stable|candidate|beta|edge)$ ]]; then
if [[ "$channel" =~ ^([0-9]+\.[0-9]+|latest)/(stable|candidate|beta|edge)$ ]]; then
version=$(snap info go | grep "$channel:" | awk '/\/.*:/ {print $2}' | awk "NR==1")
elif [[ "$channel" =~ ^[0-9]+\.[0-9]$ ]]; then
elif [[ "$channel" =~ ^([0-9]+\.[0-9]+|latest)$ ]]; then
version=$(snap info go | grep "$channel/stable:" | awk '/\/.*:/ {print $2}' | awk "NR==1")
else
# Invalid channel format
Expand Down

0 comments on commit e0b5ec4

Please sign in to comment.