-
Notifications
You must be signed in to change notification settings - Fork 5
43 lines (40 loc) · 1.1 KB
/
build.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
43
on:
pull_request:
branches: [ main ]
push:
branches: [ main ]
permissions:
contents: read
name: build-test
jobs:
lint:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@692973e3d937129bcbf40652eb9f2f61becf3332 # v4
- name: Set up Go
uses: actions/setup-go@0a12ed9d6a96ab950c8f026ed9f722fe0da7ef32 # v5
with:
go-version: 1.22.x
- run: go env
- name: go lint
run: make lint-go
build:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@692973e3d937129bcbf40652eb9f2f61becf3332 # v4
- name: Set up Go
uses: actions/setup-go@0a12ed9d6a96ab950c8f026ed9f722fe0da7ef32 # v5
with:
go-version: 1.22.x
- run: go env
- name: go build
run: go build -v ./...
- name: go test
run: go test -v ./...
- name: build catalog-cd
run: go build -o catalog-cd -v .
- name: Upload catalog-cd binary
uses: actions/upload-artifact@834a144ee995460fba8ed112a2fc961b36a5ec5a # v4.3.6
with:
name: catalog-cd-bin
path: catalog-cd