-
Notifications
You must be signed in to change notification settings - Fork 0
59 lines (50 loc) · 1.17 KB
/
pipeline.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
name: pipeline
on: [push]
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
jobs:
lint:
runs-on: ubuntu-latest
permissions:
actions: none
contents: read
steps:
- name: Check out code
uses: actions/checkout@v3
- name: Set up Go
uses: actions/setup-go@v3
with:
go-version: 1.21.3
- name: Install golangci-lint
run: go install github.com/golangci/golangci-lint/cmd/golangci-lint@latest
- name: Run Linting
run: make lint
test:
needs: lint
runs-on: ubuntu-latest
permissions:
actions: none
contents: read
steps:
- name: Check out code
uses: actions/checkout@v3
- name: Set up Go
uses: actions/setup-go@v3
with:
go-version: 1.21.3
- name: Run Tests
run: make test-coverage
release:
if: contains(github.ref, 'refs/tags/')
needs: test
runs-on: ubuntu-latest
permissions:
actions: none
contents: write
steps:
- name: Checkout code
uses: actions/checkout@v3
- name: Release
uses: softprops/action-gh-release@v1
with:
draft: false