Skip to content

Commit

Permalink
Fix linter configuration
Browse files Browse the repository at this point in the history
  • Loading branch information
nekohasekai committed Sep 14, 2024
1 parent aaaacba commit db923a2
Show file tree
Hide file tree
Showing 2 changed files with 14 additions and 10 deletions.
20 changes: 12 additions & 8 deletions .golangci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -3,18 +3,22 @@ linters:
enable:
- gofumpt
- govet
# - gci
- gci
- staticcheck
- paralleltest
- ineffassign

issues:
exclude-dirs:
- internal

linters-settings:
# gci:
# sections:
# - standard
# - prefix(github.com/sagernet/sing)
# - default
staticcheck:
go: '1.19'
gci:
custom-order: true
sections:
- standard
- prefix(github.com/sagernet/)
- default

run:
go: "1.23"
4 changes: 2 additions & 2 deletions tun_linux.go
Original file line number Diff line number Diff line change
Expand Up @@ -712,7 +712,7 @@ func (t *NativeTun) rules() []*netlink.Rule {
it.Family = unix.AF_INET
rules = append(rules, it)
}
priority++
// priority++
}
if p6 {
it = netlink.NewRule()
Expand Down Expand Up @@ -755,7 +755,7 @@ func (t *NativeTun) rules() []*netlink.Rule {
it.Table = t.options.IPRoute2TableIndex
it.Family = unix.AF_INET6
rules = append(rules, it)
priority6++
// priority6++
}
if p4 {
it = netlink.NewRule()
Expand Down

0 comments on commit db923a2

Please sign in to comment.