move lint to standalone pipeline (#123)
This commit is contained in:
parent
4c700aef49
commit
e14b6d340b
2 changed files with 36 additions and 9 deletions
11
.github/workflows/go.yml
vendored
11
.github/workflows/go.yml
vendored
|
|
@ -16,14 +16,14 @@ jobs:
|
|||
- name: Set up Go 1.x
|
||||
uses: actions/setup-go@v3
|
||||
with:
|
||||
go-version: ^1.19
|
||||
go-version: ^1.19
|
||||
id: go
|
||||
|
||||
- name: Check out code into the Go module directory
|
||||
uses: actions/checkout@v3
|
||||
with:
|
||||
fetch-depth: 0
|
||||
submodules: 'recursive'
|
||||
submodules: 'recursive'
|
||||
|
||||
# https://github.com/mvdan/github-actions-golang
|
||||
- uses: actions/cache@v3
|
||||
|
|
@ -39,13 +39,6 @@ jobs:
|
|||
with:
|
||||
setAllVars: true
|
||||
|
||||
- name: golangci-lint
|
||||
uses: golangci/golangci-lint-action@v3
|
||||
with:
|
||||
args: --timeout=60m -E gofmt --verbose --print-resources-usage --build-tags full
|
||||
env:
|
||||
GOGC: "10"
|
||||
|
||||
- name: Test lib ssh
|
||||
run: go test -v -cover ./...
|
||||
working-directory: crypto/ssh
|
||||
|
|
|
|||
34
.github/workflows/golangci-lint.yml
vendored
Normal file
34
.github/workflows/golangci-lint.yml
vendored
Normal file
|
|
@ -0,0 +1,34 @@
|
|||
name: golangci-lint
|
||||
on:
|
||||
push:
|
||||
tags:
|
||||
- v*
|
||||
branches:
|
||||
- master
|
||||
pull_request:
|
||||
permissions:
|
||||
contents: read
|
||||
# Optional: allow read access to pull request. Use with `only-new-issues` option.
|
||||
# pull-requests: read
|
||||
jobs:
|
||||
golangci:
|
||||
name: lint
|
||||
runs-on: ubuntu-latest
|
||||
steps:
|
||||
- name: Set up Go 1.x
|
||||
uses: actions/setup-go@v3
|
||||
with:
|
||||
go-version: ^1.19
|
||||
|
||||
- name: Check out code into the Go module directory
|
||||
uses: actions/checkout@v3
|
||||
with:
|
||||
fetch-depth: 0
|
||||
submodules: 'recursive'
|
||||
|
||||
- name: golangci-lint
|
||||
uses: golangci/golangci-lint-action@v3
|
||||
with:
|
||||
args: --timeout=60m -E gofmt --verbose --print-resources-usage --build-tags full
|
||||
env:
|
||||
GOGC: "10"
|
||||
Loading…
Add table
Add a link
Reference in a new issue