Skip to content

Commit

Permalink
chore: go 1.23
Browse files Browse the repository at this point in the history
lukasmalkmus committed Sep 18, 2024
1 parent b9f8212 commit 403cf7e
Showing 6 changed files with 12 additions and 6 deletions.
3 changes: 3 additions & 0 deletions .golangci.yaml
Original file line number Diff line number Diff line change
@@ -63,3 +63,6 @@ issues:
- linters:
- staticcheck
text: 'SA1019: "github.com/axiomhq/axiom-go/axiom/querylegacy"'
- linters:
- gosec
text: "G115: integer overflow conversion"
3 changes: 3 additions & 0 deletions .goreleaser.yaml
Original file line number Diff line number Diff line change
@@ -6,6 +6,9 @@ before:
hooks:
- make man

git:
prerelease_suffix: "-"

builds:
- <<: &build_defaults
binary: axiom
2 changes: 1 addition & 1 deletion Makefile
Original file line number Diff line number Diff line change
@@ -81,7 +81,7 @@ dep-clean: ## Remove obsolete dependencies
.PHONY: dep-upgrade
dep-upgrade: ## Upgrade all direct dependencies to their latest version
@echo ">> upgrading dependencies"
@$(GO) get -d $(shell $(GO) list -f '{{if not (or .Main .Indirect)}}{{.Path}}{{end}}' -m all)
@$(GO) get $(shell $(GO) list -f '{{if not (or .Main .Indirect)}}{{.Path}}{{end}}' -m all)
@make dep

.PHONY: dep
4 changes: 2 additions & 2 deletions internal/cmd/ingest/ingest.go
Original file line number Diff line number Diff line change
@@ -364,14 +364,14 @@ func run(ctx context.Context, opts *options, flushEverySet, batchSizeSet, csvFie
if res.Ingested > 0 {
fmt.Fprintf(opts.IO.ErrOut(), "%s Ingested %s\n",
cs.SuccessIcon(),
utils.Pluralize(cs, "event", int(res.Ingested)), //nolint:gosec // Not relevant here.
utils.Pluralize(cs, "event", int(res.Ingested)),
)
}

if res.Failed > 0 {
fmt.Fprintf(opts.IO.ErrOut(), "%s Failed to ingest %s:\n\n",
cs.ErrorIcon(),
utils.Pluralize(cs, "event", int(res.Failed)), //nolint:gosec // Not relevant here.
utils.Pluralize(cs, "event", int(res.Failed)),
)
for _, fail := range res.Failures {
fmt.Fprintf(opts.IO.ErrOut(), "%s: %s\n",
2 changes: 1 addition & 1 deletion internal/cmd/root/help.go
Original file line number Diff line number Diff line change
@@ -102,7 +102,7 @@ func rootHelpFunc(io *terminal.IO) func(*cobra.Command, []string) {
continue
}

s := padding.String(c.Name()+":", uint(c.NamePadding()+2)) + c.Short //nolint:gosec // Not relevant here.
s := padding.String(c.Name()+":", uint(c.NamePadding()+2)) + c.Short
if _, ok := c.Annotations["IsCore"]; ok {
coreCommands = append(coreCommands, s)
} else if _, ok := c.Annotations["IsManagement"]; ok {
4 changes: 2 additions & 2 deletions tools/loggen/main.go
Original file line number Diff line number Diff line change
@@ -3,7 +3,7 @@ package main
import (
"context"
"log/slog"
"math/rand"
"math/rand/v2"
"os"
"os/signal"
"syscall"
@@ -46,7 +46,7 @@ func main() {
logger.InfoContext(ctx, "Starting log generator", attrs)

for {
r := rand.Intn(1000) + 1 //nolint:gosec // not used for security purposes
r := rand.IntN(1000) + 1 //nolint:gosec // not used for security purposes
select {
case <-ctx.Done():
return

0 comments on commit 403cf7e

Please sign in to comment.