-
Notifications
You must be signed in to change notification settings - Fork 30
63 lines (51 loc) · 1.39 KB
/
go.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
---
name: Go
on:
push:
branches: [master]
pull_request:
jobs:
build:
name: Build
strategy:
fail-fast: false
matrix:
go: [1.16.x]
may-fail: [false]
include:
- go: tip
may-fail: true
runs-on: ubuntu-20.04
continue-on-error: ${{ matrix.may-fail }}
steps:
- name: Checkout code
uses: actions/checkout@v3
- name: Setup Go v${{ matrix.go }}
if: ${{ matrix.go != 'tip' }}
uses: actions/setup-go@v2
with:
go-version: ${{ matrix.go }}
- name: Setup Go tip
if: ${{ matrix.go == 'tip' }}
run: |
curl -OL https://github.com/AlekSi/golang-tip/releases/download/tip/master.linux-amd64.tar.gz
sudo rm -rf /usr/local/go
sudo tar -C /usr/local -xzf master.linux-amd64.tar.gz
sudo ln -vsf /usr/local/go/bin/* /usr/bin/
sudo ln -vsf /usr/local/go/bin/* /bin/
- name: Run debug commands
run: |
env
which -a go
go version
go env
- name: Install tools
run: make init
- name: Test with race detector
run: make race
- name: Gather test coverage
run: make cover
- name: Upload test coverage report to coveralls.io
uses: shogo82148/actions-goveralls@v1.5.1
with:
path-to-profile: profile.cov