From 26e4233bca4649dc27bb3ccb64cee50c2a937f23 Mon Sep 17 00:00:00 2001 From: DHR60 Date: Wed, 3 Dec 2025 13:52:20 +0800 Subject: [PATCH] Sync Go version from upstream go.mod (#171) --- .github/workflows/tidy.yml | 10 ++++++++++ 1 file changed, 10 insertions(+) diff --git a/.github/workflows/tidy.yml b/.github/workflows/tidy.yml index bab9c6e..e8b4daa 100644 --- a/.github/workflows/tidy.yml +++ b/.github/workflows/tidy.yml @@ -56,6 +56,16 @@ jobs: - name: Update and commit changes if: env.needs_update == 'true' run: | + # Sync Go version from upstream go.mod + EXTERNAL_REPO="XTLS/Xray-core" + GO_VERSION=$(curl -s https://raw.githubusercontent.com/$EXTERNAL_REPO/${{ env.LATEST_TAG_NAME }}/go.mod | awk '/^go / {print $2; exit}') + if [ -n "$GO_VERSION" ]; then + echo "Syncing Go version to $GO_VERSION" + go mod edit -go=$GO_VERSION + else + echo "Failed to detect Go version from upstream go.mod" + fi + # Lock gvisor version to a specific revision go mod edit -replace=gvisor.dev/gvisor=gvisor.dev/gvisor@v0.0.0-20250606001031-fa4c4dd86b43