From 42251b3a13b0952e6c36dcadd7469f373575a81e Mon Sep 17 00:00:00 2001 From: Ryan Emerson Date: Tue, 15 Oct 2024 13:15:15 +0100 Subject: [PATCH] Add check to ensure that no unstaged proto.lock files exist on PRs issued against release/26.x branches (#33592) Closes #33566 Signed-off-by: Ryan Emerson --- .github/actions/build-keycloak/action.yml | 2 +- .github/workflows/ci.yml | 4 ++++ 2 files changed, 5 insertions(+), 1 deletion(-) diff --git a/.github/actions/build-keycloak/action.yml b/.github/actions/build-keycloak/action.yml index a7743bc2c2..6b0e90ab64 100644 --- a/.github/actions/build-keycloak/action.yml +++ b/.github/actions/build-keycloak/action.yml @@ -35,7 +35,7 @@ runs: # Ensure this plugin is built first to avoid warnings in the build ./mvnw install -Pdistribution -am -pl distribution/maven-plugins/licenses-processor # By using "dependency:resolve", it will download all dependencies used in later stages for running the tests - ./mvnw install dependency:resolve -V -e -DskipTests -DskipExamples -DexcludeGroupIds=org.keycloak -Dsilent=true + ./mvnw install dependency:resolve -V -e -DskipTests -DskipExamples -DexcludeGroupIds=org.keycloak -Dsilent=true -DcommitProtoLockChanges=true - id: compress-keycloak-maven-repository name: Compress Keycloak Maven artifacts diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index c1022d0563..841ace6544 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -64,6 +64,10 @@ jobs: - name: Build Keycloak uses: ./.github/actions/build-keycloak + - name: Check for unstaged proto.lock files + if: github.event_name == 'pull_request' && startsWith(github.event.pull_request.base.ref, 'release/') + run: git diff --name-only --exit-code -- "**/proto.lock" + unit-tests: name: Base UT runs-on: ubuntu-latest