diff --git a/.github/workflows/update_go_modules.yml b/.github/workflows/update_go_modules.yml index 8cf2a11..bb65c5b 100644 --- a/.github/workflows/update_go_modules.yml +++ b/.github/workflows/update_go_modules.yml @@ -21,10 +21,10 @@ jobs: - name: Update Go Version id: update-go-version run: | - latest_go_version=$(curl -s https://go.dev/VERSION?m=text | head -n 1) - go mod edit -go=${latest_go_version#go} - echo "Updated go version to ${latest_go_version#go}" - echo "::set-output name=latest_go_version::${latest_go_version#go}" + latest_go_version=$(curl -s https://go.dev/VERSION?m=text | head -n 1 | awk -F 'go' '{print $2}') + go mod edit -go=${latest_go_version} + echo "Updated go version to ${latest_go_version}" + echo "::set-output name=latest_go_version::${latest_go_version}" - name: Set up Updated Go uses: actions/setup-go@v4