diff --git a/.github/workflows/cross-darwin.yml b/.github/workflows/cross-darwin.yml index d90f5bf9a..5dfab485e 100644 --- a/.github/workflows/cross-darwin.yml +++ b/.github/workflows/cross-darwin.yml @@ -19,16 +19,15 @@ jobs: if: "!contains(github.event.head_commit.message, '[ci skip]')" steps: + - name: Check out code into the Go module directory + uses: actions/checkout@v3 - name: Set up Go uses: actions/setup-go@v3 with: - go-version: 1.19 + go-version-file: go.mod id: go - - name: Check out code into the Go module directory - uses: actions/checkout@v3 - - name: macOS build cmd env: GOOS: darwin diff --git a/.github/workflows/cross-freebsd.yml b/.github/workflows/cross-freebsd.yml index 17aa14924..684e31cf2 100644 --- a/.github/workflows/cross-freebsd.yml +++ b/.github/workflows/cross-freebsd.yml @@ -19,16 +19,15 @@ jobs: if: "!contains(github.event.head_commit.message, '[ci skip]')" steps: + - name: Check out code into the Go module directory + uses: actions/checkout@v3 - name: Set up Go uses: actions/setup-go@v3 with: - go-version: 1.19 + go-version-file: go.mod id: go - - name: Check out code into the Go module directory - uses: actions/checkout@v3 - - name: FreeBSD build cmd env: GOOS: freebsd diff --git a/.github/workflows/cross-openbsd.yml b/.github/workflows/cross-openbsd.yml index 43f7dc314..cc4cd11b2 100644 --- a/.github/workflows/cross-openbsd.yml +++ b/.github/workflows/cross-openbsd.yml @@ -19,16 +19,15 @@ jobs: if: "!contains(github.event.head_commit.message, '[ci skip]')" steps: + - name: Check out code into the Go module directory + uses: actions/checkout@v3 - name: Set up Go uses: actions/setup-go@v3 with: - go-version: 1.19 + go-version-file: go.mod id: go - - name: Check out code into the Go module directory - uses: actions/checkout@v3 - - name: OpenBSD build cmd env: GOOS: openbsd diff --git a/.github/workflows/cross-wasm.yml b/.github/workflows/cross-wasm.yml index 7caeb0add..60a397add 100644 --- a/.github/workflows/cross-wasm.yml +++ b/.github/workflows/cross-wasm.yml @@ -19,16 +19,15 @@ jobs: if: "!contains(github.event.head_commit.message, '[ci skip]')" steps: + - name: Check out code into the Go module directory + uses: actions/checkout@v3 - name: Set up Go uses: actions/setup-go@v3 with: - go-version: 1.19 + go-version-file: go.mod id: go - - name: Check out code into the Go module directory - uses: actions/checkout@v3 - - name: Wasm client build env: GOOS: js diff --git a/.github/workflows/cross-windows.yml b/.github/workflows/cross-windows.yml index 90780cb19..470cc4a2f 100644 --- a/.github/workflows/cross-windows.yml +++ b/.github/workflows/cross-windows.yml @@ -19,16 +19,15 @@ jobs: if: "!contains(github.event.head_commit.message, '[ci skip]')" steps: + - name: Check out code into the Go module directory + uses: actions/checkout@v3 - name: Set up Go uses: actions/setup-go@v3 with: - go-version: 1.19 + go-version-file: go.mod id: go - - name: Check out code into the Go module directory - uses: actions/checkout@v3 - - name: Windows build cmd env: GOOS: windows diff --git a/.github/workflows/depaware.yml b/.github/workflows/depaware.yml index 34ad1a4d4..fb5fb0fc9 100644 --- a/.github/workflows/depaware.yml +++ b/.github/workflows/depaware.yml @@ -17,13 +17,13 @@ jobs: runs-on: ubuntu-latest steps: + - name: Check out code + uses: actions/checkout@v3 + - name: Set up Go uses: actions/setup-go@v3 with: - go-version: 1.19 - - - name: Check out code - uses: actions/checkout@v3 + go-version-file: go.mod - name: depaware run: go run github.com/tailscale/depaware --check diff --git a/.github/workflows/go_generate.yml b/.github/workflows/go_generate.yml index a175af93a..6f82af963 100644 --- a/.github/workflows/go_generate.yml +++ b/.github/workflows/go_generate.yml @@ -18,16 +18,16 @@ jobs: runs-on: ubuntu-latest steps: - - name: Set up Go - uses: actions/setup-go@v3 - with: - go-version: 1.19 - - name: Check out code uses: actions/checkout@v3 with: fetch-depth: 0 + - name: Set up Go + uses: actions/setup-go@v3 + with: + go-version-file: go.mod + - name: check 'go generate' is clean run: | if [[ "${{github.ref}}" == release-branch/* ]] diff --git a/.github/workflows/license.yml b/.github/workflows/license.yml index caf5f7e78..639b81c7a 100644 --- a/.github/workflows/license.yml +++ b/.github/workflows/license.yml @@ -17,13 +17,13 @@ jobs: runs-on: ubuntu-latest steps: + - name: Check out code + uses: actions/checkout@v3 + - name: Set up Go uses: actions/setup-go@v3 with: - go-version: 1.19 - - - name: Check out code - uses: actions/checkout@v3 + go-version-file: go.mod - name: Run license checker run: ./scripts/check_license_headers.sh . diff --git a/.github/workflows/linux-race.yml b/.github/workflows/linux-race.yml index f01e4d1a4..cd92d717c 100644 --- a/.github/workflows/linux-race.yml +++ b/.github/workflows/linux-race.yml @@ -19,16 +19,15 @@ jobs: if: "!contains(github.event.head_commit.message, '[ci skip]')" steps: + - name: Check out code into the Go module directory + uses: actions/checkout@v3 - name: Set up Go uses: actions/setup-go@v3 with: - go-version: 1.19 + go-version-file: go.mod id: go - - name: Check out code into the Go module directory - uses: actions/checkout@v3 - - name: Basic build run: go build ./cmd/... diff --git a/.github/workflows/linux.yml b/.github/workflows/linux.yml index a62d022af..228b701b5 100644 --- a/.github/workflows/linux.yml +++ b/.github/workflows/linux.yml @@ -19,16 +19,15 @@ jobs: if: "!contains(github.event.head_commit.message, '[ci skip]')" steps: + - name: Check out code into the Go module directory + uses: actions/checkout@v3 - name: Set up Go uses: actions/setup-go@v3 with: - go-version: 1.19 + go-version-file: go.mod id: go - - name: Check out code into the Go module directory - uses: actions/checkout@v3 - - name: Basic build run: go build ./cmd/... diff --git a/.github/workflows/linux32.yml b/.github/workflows/linux32.yml index 23ad30485..c0a64a702 100644 --- a/.github/workflows/linux32.yml +++ b/.github/workflows/linux32.yml @@ -19,16 +19,15 @@ jobs: if: "!contains(github.event.head_commit.message, '[ci skip]')" steps: + - name: Check out code into the Go module directory + uses: actions/checkout@v3 - name: Set up Go uses: actions/setup-go@v3 with: - go-version: 1.19 + go-version-file: go.mod id: go - - name: Check out code into the Go module directory - uses: actions/checkout@v3 - - name: Basic build run: GOARCH=386 go build ./cmd/... diff --git a/.github/workflows/static-analysis.yml b/.github/workflows/static-analysis.yml index b056346b8..b50cf5a9a 100644 --- a/.github/workflows/static-analysis.yml +++ b/.github/workflows/static-analysis.yml @@ -16,12 +16,12 @@ jobs: gofmt: runs-on: ubuntu-latest steps: + - name: Check out code + uses: actions/checkout@v3 - name: Set up Go uses: actions/setup-go@v3 with: - go-version: 1.19 - - name: Check out code - uses: actions/checkout@v3 + go-version-file: go.mod - name: Run gofmt (goimports) run: go run golang.org/x/tools/cmd/goimports -d --format-only . - uses: k0kubun/action-slack@v2.0.0 diff --git a/.github/workflows/vm.yml b/.github/workflows/vm.yml index 04c3bc2ff..53989bc9e 100644 --- a/.github/workflows/vm.yml +++ b/.github/workflows/vm.yml @@ -19,13 +19,13 @@ jobs: - name: Set GOPATH run: echo "GOPATH=$HOME/go" >> $GITHUB_ENV + - name: Checkout Code + uses: actions/checkout@v3 + - name: Set up Go uses: actions/setup-go@v3 with: - go-version: 1.19 - - - name: Checkout Code - uses: actions/checkout@v3 + go-version-file: go.mod - name: Run VM tests run: go test ./tstest/integration/vms -v -no-s3 -run-vm-tests -run=TestRunUbuntu2004 diff --git a/.github/workflows/windows.yml b/.github/workflows/windows.yml index 2f753c023..7b5706635 100644 --- a/.github/workflows/windows.yml +++ b/.github/workflows/windows.yml @@ -19,14 +19,13 @@ jobs: if: "!contains(github.event.head_commit.message, '[ci skip]')" steps: + - name: Checkout code + uses: actions/checkout@v3 - name: Install Go uses: actions/setup-go@v3 with: - go-version: 1.19.x - - - name: Checkout code - uses: actions/checkout@v3 + go-version-file: go.mod - name: Restore Cache uses: actions/cache@v3