-
Notifications
You must be signed in to change notification settings - Fork 338
55 lines (48 loc) · 1.35 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
44
45
46
47
48
49
50
51
52
53
54
55
name: Build
on:
push:
branches: [ main ]
pull_request:
branches: [ main ]
jobs:
git-secrets:
runs-on: 'ubuntu-22.04'
steps:
- name: Pull latest awslabs/git-secrets repo
uses: actions/checkout@v4
with:
repository: awslabs/git-secrets
ref: 1.3.0
fetch-tags: true
path: git-secrets
- name: Install git secrets from source
run: sudo make install
working-directory: git-secrets
- uses: actions/checkout@v4
- name: Scan repository for git secrets
run: |
git secrets --register-aws
git secrets --scan-history
cross-compile:
runs-on: 'ubuntu-22.04'
steps:
- uses: actions/checkout@v4
- name: Cross-compile all variants
run: make all-variants-in-docker
unit-test:
strategy:
matrix:
go: ['1.21', '1.22']
# Intentionally use specific versions instead of "latest" to
# make this build reproducible.
os: ['ubuntu-22.04', 'macos-12', 'windows-2022']
# Build all variants regardless of failures
fail-fast: false
name: unit-test (${{ matrix.os }} / Go ${{ matrix.go }})
runs-on: ${{ matrix.os }}
steps:
- uses: actions/checkout@v4
- uses: actions/setup-go@v5
with:
go-version: ${{ matrix.go }}
- run: make test