mirror of
https://github.com/restic/restic.git
synced 2025-06-02 03:33:32 +00:00
Merge pull request #5219 from MichaelEischer/ci-silence-shadow-builtin
CI: bump golangci-lint and silence warnings about shadowed builtins
This commit is contained in:
commit
d0d887138c
2
.github/workflows/tests.yml
vendored
2
.github/workflows/tests.yml
vendored
@ -259,7 +259,7 @@ jobs:
|
|||||||
uses: golangci/golangci-lint-action@v6
|
uses: golangci/golangci-lint-action@v6
|
||||||
with:
|
with:
|
||||||
# Required: the version of golangci-lint is required and must be specified without patch version: we always use the latest patch version.
|
# Required: the version of golangci-lint is required and must be specified without patch version: we always use the latest patch version.
|
||||||
version: v1.61.0
|
version: v1.63.4
|
||||||
args: --verbose --timeout 5m
|
args: --verbose --timeout 5m
|
||||||
|
|
||||||
# only run golangci-lint for pull requests, otherwise ALL hints get
|
# only run golangci-lint for pull requests, otherwise ALL hints get
|
||||||
|
@ -56,6 +56,7 @@ issues:
|
|||||||
# staticcheck: there's no easy way to replace these packages
|
# staticcheck: there's no easy way to replace these packages
|
||||||
- "SA1019: \"golang.org/x/crypto/poly1305\" is deprecated"
|
- "SA1019: \"golang.org/x/crypto/poly1305\" is deprecated"
|
||||||
- "SA1019: \"golang.org/x/crypto/openpgp\" is deprecated"
|
- "SA1019: \"golang.org/x/crypto/openpgp\" is deprecated"
|
||||||
|
- "redefines-builtin-id:"
|
||||||
|
|
||||||
exclude-rules:
|
exclude-rules:
|
||||||
# revive: ignore unused parameters in tests
|
# revive: ignore unused parameters in tests
|
||||||
|
@ -23,13 +23,6 @@ func randomID(rd io.Reader) restic.ID {
|
|||||||
|
|
||||||
const maxBlobSize = 1 << 20
|
const maxBlobSize = 1 << 20
|
||||||
|
|
||||||
func min(a, b int) int {
|
|
||||||
if a < b {
|
|
||||||
return a
|
|
||||||
}
|
|
||||||
return b
|
|
||||||
}
|
|
||||||
|
|
||||||
func fillPacks(t testing.TB, rnd *rand.Rand, pm *packerManager, buf []byte) (bytes int) {
|
func fillPacks(t testing.TB, rnd *rand.Rand, pm *packerManager, buf []byte) (bytes int) {
|
||||||
for i := 0; i < 102; i++ {
|
for i := 0; i < 102; i++ {
|
||||||
l := rnd.Intn(maxBlobSize)
|
l := rnd.Intn(maxBlobSize)
|
||||||
|
Loading…
x
Reference in New Issue
Block a user