Files
grafana/.github/workflows/pr-k8s-codegen-check.yml
dependabot[bot] 41df2e9d26 Bump actions/setup-go from 4.2.1 to 5.5.0 (#108286)
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-07-31 13:27:36 +01:00

42 lines
911 B
YAML

name: "K8s Codegen Check"
on:
workflow_dispatch:
pull_request:
branches: [main]
paths:
- "pkg/apis/**"
- "pkg/aggregator/apis/**"
- "pkg/apimachinery/apis/**"
- "hack/**"
- "apps/**"
- "*.sum"
jobs:
check:
name: K8s Codegen Check
runs-on: ubuntu-latest
steps:
- name: Checkout repository
uses: actions/checkout@v4
with:
persist-credentials: false
- name: Set go version
uses: actions/setup-go@d35c59abb061a4a6fb18e82ac0862c26744d6ab5
with:
go-version-file: go.mod
- name: Update k8s codegen
run: ./hack/update-codegen.sh
- name: Check for k8s codegen changes
run: |
if ! git diff --exit-code --quiet; then
echo "Changes detected:"
git diff
echo "Please run './hack/update-codegen.sh' and commit the changes."
exit 1
fi