File tree Expand file tree Collapse file tree 1 file changed +30
-7
lines changed
Expand file tree Collapse file tree 1 file changed +30
-7
lines changed Original file line number Diff line number Diff line change 1- name : Lint and Test
1+ name : Go
2+
23on :
4+ workflow_dispatch :
5+ push :
6+ branches : [master]
7+ paths :
8+ - " **.go"
9+ - " go.mod"
10+ - " go.sum"
311 pull_request :
4-
5- permissions :
6- contents : read
12+ branches : [master]
13+ paths :
14+ - " **.go"
15+ - " go.mod"
16+ - " go.sum"
717
818jobs :
919 golangci :
1020 name : Lint
1121 runs-on : ubuntu-latest
1222 steps :
13- - uses : actions/checkout@v4
14- - uses : actions/setup-go@v5
23+ # step 1: checkout repository code
24+ - name : Checkout code into workspace directory
25+ uses : actions/checkout@v4
26+
27+ # step 2: set up go
28+ - name : Set up Go
29+ uses : actions/setup-go@v5
1530 with :
1631 go-version : stable
17- - name : golangci-lint
32+
33+ # step 3: run golangci-lint
34+ - name : Run golangci-lint
1835 uses : golangci/golangci-lint-action@v6
1936 with :
2037 version : latest
4158 # step 4: run test
4259 - name : Run coverage
4360 run : go test -race -coverprofile=coverage.out -covermode=atomic ./...
61+
62+ # step 5: upload coverage
63+ # - name: Upload coverage to Codecov
64+ # uses: codecov/codecov-action@v4
65+ # with:
66+ # token: ${{ secrets.CODECOV_TOKEN }}
You can’t perform that action at this time.
0 commit comments