Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
14 changes: 0 additions & 14 deletions .bingo/.gitignore

This file was deleted.

13 changes: 0 additions & 13 deletions .bingo/README.md

This file was deleted.

37 changes: 0 additions & 37 deletions .bingo/Variables.mk

This file was deleted.

1 change: 0 additions & 1 deletion .bingo/go.mod

This file was deleted.

5 changes: 0 additions & 5 deletions .bingo/goimports.mod

This file was deleted.

18 changes: 0 additions & 18 deletions .bingo/goimports.sum

This file was deleted.

5 changes: 0 additions & 5 deletions .bingo/golangci-lint.mod

This file was deleted.

14 changes: 0 additions & 14 deletions .bingo/variables.env

This file was deleted.

2 changes: 1 addition & 1 deletion .golangci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
# This is the baseline configuration for all HyperFleet Go repositories.
# See standards/linting.md for full documentation of this standard.
#
# golangci-lint should be installed and versioned via bingo in each repository.
# golangci-lint is installed via `go install` with a versioned binary managed in the Makefile.

version: "2"

Expand Down
2 changes: 1 addition & 1 deletion CONTRIBUTING.md
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@

### Prerequisites

- Go 1.25.0 or later
- Go 1.26.0 or later
- Access to a Kubernetes cluster with Maestro installed
- Docker (for building container images)

Expand Down
2 changes: 1 addition & 1 deletion Dockerfile
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
ARG BASE_IMAGE=gcr.io/distroless/static-debian12:nonroot

# Build stage
FROM golang:1.25-alpine AS builder
FROM golang:1.26.0-alpine AS builder

# Git commit passed from build machine (avoids installing git in container)
ARG GIT_COMMIT=unknown
Expand Down
24 changes: 17 additions & 7 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -31,6 +31,11 @@ GOTEST := $(GOCMD) test
GOMOD := $(GOCMD) mod
GOFMT := gofmt

# Invoke a pinned tool: $(call gotool,name)
# All tools share tools/go.mod with Go 1.24+ tool directives.
TOOL_MOD := tools/go.mod
gotool = "$(GOCMD)" tool -modfile="$(TOOL_MOD)" $(1)

Comment thread
kuudori marked this conversation as resolved.
# Test parameters
TEST_TIMEOUT := 30m
RACE_FLAG := -race
Expand Down Expand Up @@ -69,9 +74,6 @@ BINDIR ?= $(GOPATH)/bin
# Find all Go packages, excluding vendor and test directories
PKG_DIRS := $(shell $(GOCMD) list ./... 2>/dev/null | grep -v /vendor/ | grep -v /test/)

# Include bingo-managed tool versions
include .bingo/Variables.mk

.PHONY: help
help: ## Display this help message
@echo "Available targets:"
Expand Down Expand Up @@ -102,21 +104,29 @@ test-all: test lint ## Run all tests and checks (unit + lint)
@echo "━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━"

.PHONY: lint
lint: $(GOLANGCI_LINT) ## Run golangci-lint
lint: ## Run golangci-lint
@echo "Running golangci-lint..."
$(GOLANGCI_LINT) cache clean && $(GOLANGCI_LINT) run
$(call gotool,golangci-lint) run ./...

.PHONY: fmt
fmt: $(GOIMPORTS) ## Format code with gofmt and goimports
fmt: ## Format code with gofmt and goimports
@echo "Formatting code..."
$(GOIMPORTS) -w .
$(GOCMD) tool goimports -w .

.PHONY: tools
tools: ## Ensure tool dependencies are up to date
cd tools && "$(GOCMD)" mod tidy

.PHONY: mod-tidy
mod-tidy: ## Tidy Go module dependencies
@echo "Tidying Go modules..."
$(GOMOD) tidy
$(GOMOD) verify

.PHONY: verify-tools
verify-tools: tools ## Fail in CI if tool module drifted
@git diff --exit-code HEAD -- tools/go.mod tools/go.sum || (echo "tool modules out of date; run 'make tools'" && exit 1)

.PHONY: binary
binary: ## Build binary
@echo "Building $(PROJECT_NAME)..."
Expand Down
8 changes: 7 additions & 1 deletion go.mod
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
module github.com/openshift-hyperfleet/maestro-cli

go 1.25.4
go 1.26.0

require (
github.com/atotto/clipboard v0.1.4
Expand Down Expand Up @@ -77,12 +77,16 @@ require (
go.uber.org/zap v1.27.1 // indirect
go.yaml.in/yaml/v2 v2.4.3 // indirect
go.yaml.in/yaml/v3 v3.0.4 // indirect
golang.org/x/mod v0.30.0 // indirect
golang.org/x/net v0.48.0 // indirect
golang.org/x/oauth2 v0.34.0 // indirect
golang.org/x/sync v0.19.0 // indirect
golang.org/x/sys v0.39.0 // indirect
golang.org/x/telemetry v0.0.0-20251111182119-bc8e575c7b54 // indirect
golang.org/x/term v0.38.0 // indirect
golang.org/x/text v0.32.0 // indirect
golang.org/x/time v0.14.0 // indirect
golang.org/x/tools v0.39.0 // indirect
google.golang.org/genproto/googleapis/rpc v0.0.0-20251202230838-ff82c1b0f217 // indirect
google.golang.org/grpc v1.79.3 // indirect
google.golang.org/protobuf v1.36.11 // indirect
Expand All @@ -99,3 +103,5 @@ require (
sigs.k8s.io/randfill v1.0.0 // indirect
sigs.k8s.io/structured-merge-diff/v6 v6.3.0 // indirect
)

tool golang.org/x/tools/cmd/goimports
2 changes: 2 additions & 0 deletions go.sum
Original file line number Diff line number Diff line change
Expand Up @@ -218,6 +218,8 @@ golang.org/x/sys v0.0.0-20210809222454-d867a43fc93e/go.mod h1:oPkhp1MJrh7nUepCBc
golang.org/x/sys v0.6.0/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg=
golang.org/x/sys v0.39.0 h1:CvCKL8MeisomCi6qNZ+wbb0DN9E5AATixKsvNtMoMFk=
golang.org/x/sys v0.39.0/go.mod h1:OgkHotnGiDImocRcuBABYBEXf8A9a87e/uXjp9XT3ks=
golang.org/x/telemetry v0.0.0-20251111182119-bc8e575c7b54 h1:E2/AqCUMZGgd73TQkxUMcMla25GB9i/5HOdLr+uH7Vo=
golang.org/x/telemetry v0.0.0-20251111182119-bc8e575c7b54/go.mod h1:hKdjCMrbv9skySur+Nek8Hd0uJ0GuxJIoIX2payrIdQ=
golang.org/x/term v0.38.0 h1:PQ5pkm/rLO6HnxFR7N2lJHOZX6Kez5Y1gDSJla6jo7Q=
golang.org/x/term v0.38.0/go.mod h1:bSEAKrOT1W+VSu9TSCMtoGEOUcKxOKgl3LE5QEF/xVg=
golang.org/x/text v0.3.0/go.mod h1:NqM8EUOU14njkJ3fqMW+pc6Ldnwhi/IjpwHt7yyuwOQ=
Expand Down
Loading