File tree Expand file tree Collapse file tree 3 files changed +18
-26
lines changed
Expand file tree Collapse file tree 3 files changed +18
-26
lines changed Original file line number Diff line number Diff line change 3838 cache : false
3939 - name : golangci-lint
4040 uses : golangci/golangci-lint-action@v6
41+ env :
42+ GOLANGCI_LINT_SKIP_GOVERSION_CHECK : " 1"
4143 with :
4244 # NOTE: Keep this in sync with the version from .golangci.yml
43- version : ' v1.56.2 '
45+ version : ' v2.5.0 '
Original file line number Diff line number Diff line change 1- # Created based on v1.56.1
2- # NOTE: Keep this in sync with the version in .github/workflows/linter .yml
1+ # Created for golangci-lint v2.5.0
2+ # NOTE: Keep this in sync with the version in .github/workflows/golangci-lint .yml
33
44version : 2
55
@@ -38,10 +38,6 @@ linters-settings:
3838 disabled-checks :
3939 - ifElseChain
4040
41- gofumpt :
42- module-path : github.com/gofiber/template
43- extra-rules : true
44-
4541 gosec :
4642 excludes :
4743 - G104 # Provided by errcheck
@@ -131,22 +127,11 @@ linters-settings:
131127 - name : use-any # TODO Enable for v3 release
132128 disabled : true
133129
134- stylecheck :
135- checks :
136- - all
137- - -ST1000
138- - -ST1020
139- - -ST1021
140- - -ST1022
141-
142130 tagliatelle :
143131 case :
144132 rules :
145133 json : snake
146134
147- tenv :
148- all : true
149-
150135 # unparam:
151136 # check-exported: true
152137
@@ -155,6 +140,15 @@ linters-settings:
155140 - github.com/gofiber/fiber/*
156141 - github.com/valyala/fasthttp
157142
143+ formatters :
144+ enable :
145+ - gofumpt
146+ - goimports
147+ settings :
148+ gofumpt :
149+ module-path : github.com/gofiber/template
150+ extra-rules : true
151+
158152issues :
159153 exclude-use-default : false
160154 exclude-dirs-use-default : false
@@ -185,13 +179,9 @@ linters:
185179 - gochecksumtype
186180 - goconst
187181 - gocritic
188- - gofmt
189- - gofumpt
190- - goimports
191182 - gomoddirectives
192183 - goprintffuncname
193184 - gosec
194- - gosimple
195185 - gosmopolitan
196186 - govet
197187 - grouper
@@ -214,7 +204,6 @@ linters:
214204 - rowserrcheck
215205 - sqlclosecheck
216206 - staticcheck
217- - stylecheck
218207 - tagalign
219208 - tagliatelle
220209 - testifylint
@@ -227,5 +216,5 @@ linters:
227216 - usestdlibvars
228217 - wastedassign
229218 - whitespace
219+ - unqueryvet
230220 - wrapcheck
231- - tenv
Original file line number Diff line number Diff line change 1+ // Package template provides shared rendering primitives for Fiber template engines.
12package template
23
34import (
@@ -113,8 +114,8 @@ func (e *Engine) Reload(enabled bool) IEngineCore {
113114 return e
114115}
115116
116- // Check if the engine should reload the templates before rendering
117- // Explicit Mute Unlock vs defer offers better performance
117+ // PreRenderCheck determines if the engine should reload the templates before rendering.
118+ // Explicit mutex unlock vs defer offers better performance.
118119func (e * Engine ) PreRenderCheck () bool {
119120 e .Mutex .Lock ()
120121
You can’t perform that action at this time.
0 commit comments