Move golangci-lint from circle-ci to github actions (#8975)

* Move lint to github actions

* Update version

* timeout and scheduled trigger
This commit is contained in:
Sebastian Spaink 2021-03-11 14:35:10 -06:00 committed by GitHub
parent 1b7a52d0b6
commit 1d8a65069f
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 23 additions and 10 deletions

View File

@ -71,14 +71,6 @@ commands:
paths:
- 'dist'
jobs:
linter:
executor: go-1_16
steps:
- checkout
- restore_cache:
key: go-mod-v1-{{ checksum "go.sum" }}
- run: wget -O- -nv https://raw.githubusercontent.com/golangci/golangci-lint/master/install.sh | sh -s -- -b $(go env GOPATH)/bin v1.37.0
- run: make lint
deps:
executor: go-1_16
steps:
@ -209,7 +201,6 @@ workflows:
version: 2
check:
jobs:
- 'linter'
- 'macdeps':
filters:
tags:
@ -287,7 +278,6 @@ workflows:
only: /.*/
nightly:
jobs:
- 'linter'
- 'deps'
- 'macdeps'
- 'test-go-1_15':

23
.github/workflows/golangci-lint.yml vendored Normal file
View File

@ -0,0 +1,23 @@
name: golangci-lint
on:
push:
branches:
- master
pull_request:
branches:
- master
schedule:
# Trigger every day at 16:00 UTC
- cron: '0 16 * * *'
jobs:
golangci-pr:
name: lint
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- name: golangci-lint
uses: golangci/golangci-lint-action@v2
with:
version: v1.38
only-new-issues: true
args: --timeout=5m0s