Compare commits
2 commits
0e036c7c7d
...
fa8a0c95ee
Author | SHA1 | Date | |
---|---|---|---|
fa8a0c95ee | |||
1f1a3885e0 |
2 changed files with 34 additions and 14 deletions
22
.forgejo/workflows/test.yml
Normal file
22
.forgejo/workflows/test.yml
Normal file
|
@ -0,0 +1,22 @@
|
||||||
|
on: [push]
|
||||||
|
jobs:
|
||||||
|
linting:
|
||||||
|
runs-on: docker
|
||||||
|
steps:
|
||||||
|
- uses: actions/checkout@v4
|
||||||
|
- uses: actions/setup-go@v5
|
||||||
|
with:
|
||||||
|
go-version: stable
|
||||||
|
- uses: https://github.com/golangci/golangci-lint-action@v4
|
||||||
|
tests:
|
||||||
|
runs-on: docker
|
||||||
|
steps:
|
||||||
|
- uses: actions/checkout@v4
|
||||||
|
- uses: actions/setup-go@v5
|
||||||
|
with:
|
||||||
|
go-version: stable
|
||||||
|
- name: Install dependencies
|
||||||
|
run: go get .
|
||||||
|
- name: Run tests
|
||||||
|
run: go test
|
||||||
|
|
|
@ -324,16 +324,14 @@ linters-settings:
|
||||||
# minimal confidence for issues, default is 0.8
|
# minimal confidence for issues, default is 0.8
|
||||||
min-confidence: 0.8
|
min-confidence: 0.8
|
||||||
|
|
||||||
gomnd:
|
mnd:
|
||||||
settings:
|
# the list of enabled checks, see https://github.com/tommy-muehle/go-mnd/#checks for description.
|
||||||
mnd:
|
checks: argument,case,condition,operation,return,assign
|
||||||
# the list of enabled checks, see https://github.com/tommy-muehle/go-mnd/#checks for description.
|
# for files perm: 384=0o600
|
||||||
checks: argument,case,condition,operation,return,assign
|
ignored-numbers: 0o600,384,0o700,0o744
|
||||||
# for files perm: 384=0o600
|
# test files are ignored by default
|
||||||
ignored-numbers: 0o600,384,0o700,0o744
|
# ignored-files:
|
||||||
# test files are ignored by default
|
# ignored-functions: math.*
|
||||||
# ignored-files:
|
|
||||||
# ignored-functions: math.*
|
|
||||||
|
|
||||||
gomoddirectives:
|
gomoddirectives:
|
||||||
# Allow local `replace` directives. Default is false.
|
# Allow local `replace` directives. Default is false.
|
||||||
|
@ -395,9 +393,6 @@ linters-settings:
|
||||||
checks: [ "all" ]
|
checks: [ "all" ]
|
||||||
|
|
||||||
govet:
|
govet:
|
||||||
# report about shadowed variables
|
|
||||||
check-shadowing: true
|
|
||||||
|
|
||||||
# settings per analyzer
|
# settings per analyzer
|
||||||
#settings:
|
#settings:
|
||||||
# printf: # analyzer name, run `go tool vet help` to see all analyzers
|
# printf: # analyzer name, run `go tool vet help` to see all analyzers
|
||||||
|
@ -411,7 +406,7 @@ linters-settings:
|
||||||
# run `go tool vet help` to see all analyzers
|
# run `go tool vet help` to see all analyzers
|
||||||
#enable:
|
#enable:
|
||||||
# - atomicalign
|
# - atomicalign
|
||||||
#enable-all: false
|
enable-all: false
|
||||||
#disable:
|
#disable:
|
||||||
# - shadow
|
# - shadow
|
||||||
#disable-all: false
|
#disable-all: false
|
||||||
|
@ -675,10 +670,13 @@ linters:
|
||||||
disable:
|
disable:
|
||||||
- depguard
|
- depguard
|
||||||
- dogsled
|
- dogsled
|
||||||
|
- execinquery # deprecated
|
||||||
- exhaustivestruct
|
- exhaustivestruct
|
||||||
|
- exhaustruct
|
||||||
- godox
|
- godox
|
||||||
- goheader
|
- goheader
|
||||||
- golint
|
- golint
|
||||||
|
- gomnd # deprecated
|
||||||
- interfacer
|
- interfacer
|
||||||
- ireturn
|
- ireturn
|
||||||
- maligned
|
- maligned
|
||||||
|
|
Loading…
Reference in a new issue