Skip to content

Commit

Permalink
make generate-otlp: check that tools are installed (#10285)
Browse files Browse the repository at this point in the history
Signed-off-by: Oleg Zaytsev <[email protected]>
  • Loading branch information
colega authored Jan 30, 2025
1 parent b26705d commit 562920e
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion pkg/distributor/otlp/generate.sh
Original file line number Diff line number Diff line change
Expand Up @@ -3,8 +3,11 @@

set -euo pipefail

command -v gopatch >/dev/null 2>&1 || { echo "Please install gopatch. Run 'go install github.com/uber-go/gopatch@latest' or visit https://github.com/uber-go/gopatch for more info."; exit 1; }
command -v goimports >/dev/null 2>&1 || { echo "Please install goimports. Run 'go install golang.org/x/tools/cmd/goimports@latest' or visit https://pkg.go.dev/golang.org/x/tools/cmd/goimports for more info."; exit 1; }

# Use GNU sed on MacOS falling back to `sed` everywhere else
SED=sed
SED="sed"
type gsed >/dev/null 2>&1 && SED=gsed

FILES=$(find ../../../vendor/github.com/prometheus/prometheus/storage/remote/otlptranslator/prometheusremotewrite -name '*.go' ! -name timeseries.go ! -name "*_test.go")
Expand Down

0 comments on commit 562920e

Please sign in to comment.