Added golangci-lint run check to repo. Currently enables only the defaults. https://golangci-lint.run/usage/linters
This commit is contained in:
parent
c1c9cfe118
commit
76a5d6bba3
2
.github/workflows/ci.yml
vendored
2
.github/workflows/ci.yml
vendored
@ -54,4 +54,4 @@ jobs:
|
||||
CLIENT_ID: ${{ secrets.CLIENT_ID }}
|
||||
CLIENT_SECRET: ${{ secrets.CLIENT_SECRET }}
|
||||
TENANT_ID: ${{ secrets.TENANT_ID }}
|
||||
run: go test ./...
|
||||
run: go test ./...
|
||||
|
||||
33
.github/workflows/lint.yml
vendored
Normal file
33
.github/workflows/lint.yml
vendored
Normal file
@ -0,0 +1,33 @@
|
||||
name: Linting of Source Code
|
||||
on:
|
||||
push:
|
||||
branches: [main]
|
||||
pull_request:
|
||||
branches: [main]
|
||||
|
||||
jobs:
|
||||
Linting:
|
||||
environment: Testing
|
||||
runs-on: ubuntu-latest
|
||||
defaults:
|
||||
run:
|
||||
working-directory: src
|
||||
steps:
|
||||
- name: Checkout src code
|
||||
uses: actions/checkout@v3
|
||||
|
||||
- name: Golang Setup
|
||||
uses: actions/setup-go@v3
|
||||
with:
|
||||
go-version: 1.18
|
||||
|
||||
- name: Download package dependencies
|
||||
run: go mod download
|
||||
|
||||
- name: Go Lint
|
||||
uses: golangci/golangci-lint-action@v3.2.0
|
||||
with:
|
||||
version: v1.45.2
|
||||
working-directory: ./src
|
||||
args: --timeout=15m
|
||||
skip-pkg-cache: true
|
||||
Loading…
x
Reference in New Issue
Block a user