Skip to content

PR #696 check (a241232182f92bd51712d35e55e3b170115d5d55) #2113

PR #696 check (a241232182f92bd51712d35e55e3b170115d5d55)

PR #696 check (a241232182f92bd51712d35e55e3b170115d5d55) #2113

Workflow file for this run

name: PR check
run-name: "PR #${{ github.event.number }} check (${{ github.sha }})"
on:
push:
branches: [ main ]
pull_request:
jobs:
static-checks:
runs-on: ubuntu-22.04
steps:
- name: Check out repository code
uses: actions/checkout@v4
with:
fetch-depth: '0'
- name: Check License Header
uses: apache/skywalking-eyes/header@main
- name: Setup Go
uses: actions/setup-go@v5
with:
go-version-file: ./go.mod
- name: Setup goimports
run: go install golang.org/x/tools/cmd/[email protected]
- name: Check go.mod and go.sum
run: go mod tidy && git diff --exit-code
- name: Check generated code
run: GOPATH=$(go env GOPATH) make codegen && git diff --exit-code
- name: Check format
run: goimports -l -w . && git diff --exit-code
- name: Run vet check
run: go vet ./...
- name: Run linters
uses: golangci/golangci-lint-action@v6
with:
version: v1.54.2
skip-pkg-cache: true
unit-tests:
runs-on: ubuntu-latest
steps:
- name: checkout
uses: actions/checkout@v4
with:
fetch-tags: true
- name: set up go
uses: actions/setup-go@v5
with:
go-version-file: ./go.mod
- name: setup tparse
run: go install github.com/mfridman/tparse@latest
- name: run build
run: make build
- name: run unit tests
run: make unit-tests