-
Notifications
You must be signed in to change notification settings - Fork 0
42 lines (33 loc) · 975 Bytes
/
cicd.yaml
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
name: cicd
on: push
permissions:
contents: write
jobs:
cicd:
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v4
with:
fetch-depth: 0
- name: Set up Go
uses: actions/setup-go@v4
with:
go-version: "~1.21"
- name: Set up Ebitengine
run: sudo apt -y install libc6-dev libgl1-mesa-dev libxcursor-dev libxi-dev libxinerama-dev libxrandr-dev libxxf86vm-dev libasound2-dev pkg-config
- name: Run go vet
run: go vet ./...
- name: Install XVFB
run: sudo apt -y install xvfb
- name: Run unit tests
run: xvfb-run go test ./...
- name: Run GoReleaser
uses: goreleaser/goreleaser-action@v5
if: startsWith(github.ref, 'refs/tags/')
with:
distribution: goreleaser
version: '~> v1'
args: release --clean
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}