]> Sergey Matveev's repositories - btrtrc.git/commitdiff
Use gotip for CI build
authorMatt Joiner <anacrolix@gmail.com>
Thu, 23 Dec 2021 21:33:38 +0000 (08:33 +1100)
committerMatt Joiner <anacrolix@gmail.com>
Sat, 22 Jan 2022 07:40:33 +0000 (18:40 +1100)
.github/workflows/go.yml

index a575eb35bf35f11e9012a0f40499376980aca5ab..f8884c2cac361de4ded56d57d848ca00c056b882 100644 (file)
@@ -9,16 +9,26 @@ jobs:
     runs-on: ubuntu-latest
     strategy:
       matrix:
-        go-version: [ '1.16', '1.17' ]
+        go-version: [ 'tip' ]
       fail-fast: false
     steps:
     - uses: actions/checkout@v2
 
     - name: Set up Go
+      if: matrix.go-version != 'tip'
       uses: actions/setup-go@v2
       with:
         go-version: ${{ matrix.go-version }}
 
+    - name: Install gotip
+      if: matrix.go-version == 'tip'
+      run: |
+        git clone --depth=1 https://go.googlesource.com/go "$HOME/gotip"
+        cd "$HOME/gotip/src"
+        ./make.bash
+        echo "GOROOT=$HOME/gotip" >> "$GITHUB_ENV"
+        echo "$HOME/gotip/bin:$PATH" >> "$GITHUB_PATH"
+
     - name: Test
       run: go test -race -count 2 ./...