-
Notifications
You must be signed in to change notification settings - Fork 2
74 lines (63 loc) · 1.8 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
64
65
66
67
68
69
70
71
72
73
74
name: CI
on:
push:
branches: [ "master" ]
pull_request:
branches: [ "master" ]
jobs:
build:
name: Build and Test
strategy:
fail-fast: false
matrix:
os: [ubuntu-latest, macos-latest, windows-latest]
go-version: [1.21.x,1.22.x]
runs-on: ${{ matrix.os }}
steps:
- uses: actions/checkout@v4
- name: Set up Go
uses: actions/setup-go@v5
with:
go-version: ${{ matrix.go-version }}
- name: Build
run: make build
- name: Test and Coverage
run: make cover
- name: Coveralls
uses: shogo82148/actions-goveralls@v1
with:
path-to-profile: ./tmp/cover.out
license-scan:
name: License scan
if: github.repository == 'bartventer/docstore-gen' && github.event_name == 'push'
needs: [build]
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- name: Install FOSSA
run: |
curl -H 'Cache-Control: no-cache' https://raw.githubusercontent.com/fossas/fossa-cli/master/install-latest.sh | bash
- name: Run FOSSA analyze
env:
FOSSA_API_KEY: ${{ secrets.FOSSA_API_KEY }}
run: fossa analyze
- name: Run FOSSA test
env:
FOSSA_API_KEY: ${{ secrets.FOSSA_API_KEY }}
run: fossa test
semantic-release:
name: Semantic Release
needs: [license-scan]
runs-on: ubuntu-latest
permissions:
contents: write
issues: write
steps:
- uses: actions/checkout@v4
- name: Run semantic-release
if: github.repository == 'bartventer/docstore-gen' && github.event_name == 'push'
run: |
yarn global add semantic-release@17
semantic-release
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}