Skip to content

feat: add OTel metrics with Prometheus exporter and ServiceMonitor auto-creation #196

feat: add OTel metrics with Prometheus exporter and ServiceMonitor auto-creation

feat: add OTel metrics with Prometheus exporter and ServiceMonitor auto-creation #196

Workflow file for this run

name: Check Format
on:
push:
branches: [ "main" ]
pull_request:
branches: [ "main" ]
permissions:
contents: read
jobs:
check-format:
name: Check go fmt and go mod tidy
runs-on: ubuntu-latest
steps:
- name: Checkout the code
uses: actions/checkout@v7.0.0
- name: Setup Go
uses: actions/setup-go@v6.4.0
with:
go-version-file: go.mod
- name: Run go mod tidy
run: go mod tidy
- name: Run go fmt
run: make fmt
- name: Check for uncommitted changes
run: |
if [ -n "$(git status --porcelain)" ]; then
echo "❌ Error: go mod tidy or make fmt caused changes to committed files"
echo
echo "Please run the following commands locally and commit the changes:"
echo " go mod tidy"
echo " make fmt"
echo
echo "Changed files:"
git status --porcelain
echo
echo "Diff:"
git diff
exit 1
fi
echo "✅ No formatting issues found"