Skip to content

rollback version of go to 1.18 as minimal supported (#54) #239

rollback version of go to 1.18 as minimal supported (#54)

rollback version of go to 1.18 as minimal supported (#54) #239

Workflow file for this run

name: "Code Analysis"
on:
push:
tags:
- v*
branches:
- main
pull_request:
schedule:
- cron: "0 0 * * 0"
concurrency:
group: ${{ format('{0}-{1}', github.workflow, github.head_ref) }}
cancel-in-progress: true
jobs:
CodeQL:
runs-on: ubuntu-latest
permissions:
security-events: write
steps:
- name: Checkout repository
uses: actions/checkout@v4
- name: Initialize CodeQL
uses: github/codeql-action/init@v3
with:
languages: go
- name: Perform CodeQL Analysis
uses: github/codeql-action/analyze@v3
UnitTests:
runs-on: ubuntu-latest
strategy:
matrix:
go:
- "1.18"
- "1.19"
- "1.20"
- "1.21"
- "1.22"
steps:
- name: Checkout repository
uses: actions/checkout@v4
- name: Install Go
uses: actions/setup-go@v5
with:
go-version: ${{ matrix.go }}
- name: gofmt
run: diff -u <(echo -n) <(gofmt -l . )
- name: go vet
run: go vet ./...
- name: fieldalignment
run: go vet -vettool=$(which fieldalignment) ./...
- name: Run Unit Tests
run: go test -race -cover -coverprofile=coverage.out -covermode=atomic ./...
- name: Codecov
uses: codecov/[email protected]
with:
file: ./coverage.out