Skip to content

Commit

Permalink
Merge pull request #256 from NETWAYS/update/linter_config
Browse files Browse the repository at this point in the history
Update/linter config
  • Loading branch information
RincewindsHat authored Nov 25, 2024
2 parents 5e67fe8 + 4ddb08e commit 4cb1d2a
Show file tree
Hide file tree
Showing 4 changed files with 17 additions and 5 deletions.
2 changes: 1 addition & 1 deletion .github/workflows/golangci-lint.yml
Original file line number Diff line number Diff line change
Expand Up @@ -17,4 +17,4 @@ jobs:
- name: golangci-lint
uses: golangci/golangci-lint-action@v6
with:
version: v1.54
version: v1.61
4 changes: 2 additions & 2 deletions .golangci.yml
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
run:
timeout: 5m
skip-files:

issues.exclude-files:
- '(.+)_test\.go'

linters:
Expand All @@ -14,7 +15,6 @@ linters:
- wsl
- exportloopref
disable:
- scopelint
presets:
- bugs
- unused
Expand Down
8 changes: 7 additions & 1 deletion internal/s3/bucket.go
Original file line number Diff line number Diff line change
Expand Up @@ -16,10 +16,16 @@ type V2Output struct {
}

func (v *V2Output) GetBucketOutput(size int64, status int) (output string) {
var tmp_size uint64

if size >= 0 {
tmp_size = uint64(size)
}

output = fmt.Sprintf(" \\_[%s] %s - value: %s",
check.StatusText(status),
*v.V2Output.Name,
convert.BytesIEC(size))
convert.BytesIEC(tmp_size))

return
}
Expand Down
8 changes: 7 additions & 1 deletion internal/s3/object.go
Original file line number Diff line number Diff line change
Expand Up @@ -7,10 +7,16 @@ import (
)

func (v *V2Output) GetObjectOutput(size int64, status int, path string) (output string) {
var tmp_size uint64

if size >= 0 {
tmp_size = uint64(size)
}

output += fmt.Sprintf(" \\_[%s] %s: %s\n",
check.StatusText(status),
path,
convert.BytesIEC(size))
convert.BytesIEC(tmp_size))

return
}

0 comments on commit 4cb1d2a

Please sign in to comment.