-
Notifications
You must be signed in to change notification settings - Fork 124
55 lines (46 loc) · 1.42 KB
/
check.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
name: Check
on:
workflow_dispatch:
push:
branches: [ "main", "dev","feature/*" ]
pull_request:
branches: [ "main", "dev","feature/*" ]
concurrency:
group: ${{ github.workflow }}-${{ github.ref }}
cancel-in-progress: ${{ startsWith(github.ref, 'refs/pull/') }}
env:
kyanos_log_option: --bpf-event-log-level 5 --conntrack-log-level 5
permissions:
contents: read
jobs:
go:
timeout-minutes: 30
continue-on-error: true
# TODO:adapt to different architecture runner
runs-on: ${{ matrix.os }}
# https://docs.github.com/en/actions/using-github-hosted-runners/using-github-hosted-runners/about-github-hosted-runners#standard-github-hosted-runners-for-public-repositories
strategy:
matrix:
include:
- os: "ubuntu-20.04"
name: "focal"
- os: "ubuntu-22.04"
name: "jammy"
- os: "ubuntu-24.04"
name: "noble"
steps:
- uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4
with:
submodules: recursive
- name: Set up Go
uses: actions/setup-go@3041bf56c941b39c61721a86cd11f3bb1338122a # v5
with:
go-version: '1.23.3'
- name: Build
run: |
/bin/bash init_env.sh
- name: Format
run: |
make format-go
git diff --exit-code --quiet || { echo "Code formatting issues detected"; exit 1; }
if: success()