From c54914cabc023572a0101ff47ee7cd669ca9ed1c Mon Sep 17 00:00:00 2001 From: AlejandroHerr Date: Sat, 6 Sep 2025 13:06:29 +0200 Subject: [PATCH] ci: use go mod tidy diff --- .github/workflows/_ci.yaml | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) diff --git a/.github/workflows/_ci.yaml b/.github/workflows/_ci.yaml index 5770fbd..d1468fc 100644 --- a/.github/workflows/_ci.yaml +++ b/.github/workflows/_ci.yaml @@ -36,4 +36,11 @@ jobs: with: go-version: ${{ inputs.go-version }} cache: true - - uses: katexochen/go-tidy-check@v2 + - name: Check if go.mod is tidy + run: | + go mod tidy -diff + if [ -n "$(go mod tidy -diff)" ]; then + echo "::error::go.mod or go.sum files are not tidy" + echo "Please run 'go mod tidy' and commit the changes" + exit 1 + fi