From 280d3e2ef0af683c786abb79289790e55e3d7b33 Mon Sep 17 00:00:00 2001 From: romeroalx Date: Mon, 4 Dec 2023 16:39:02 +0100 Subject: [PATCH] added look up for binaries step --- .github/workflows/codeql-analysis.yml | 13 ++++++++++++- 1 file changed, 12 insertions(+), 1 deletion(-) diff --git a/.github/workflows/codeql-analysis.yml b/.github/workflows/codeql-analysis.yml index 50f53025ad..55538e2c59 100644 --- a/.github/workflows/codeql-analysis.yml +++ b/.github/workflows/codeql-analysis.yml @@ -250,7 +250,7 @@ jobs: check-clang-tidy: needs: analyze - runs-on: ubuntu-20.04 + runs-on: ubuntu-22.04 name: Check whether clang-tidy succeeded steps: - run: | @@ -266,3 +266,14 @@ jobs: echo "::error::Rec clang-tidy failed" exit 1 fi + + check-for-binaries: + runs-on: ubuntu-22.04 + name: Force failure in case there are binaries present in a pull request + if: ${{ github.event_name == 'pull_request' }} + steps: + - name: Checkout repository + uses: actions/checkout@v4 + with: + fetch-depth: 2 + - run: if [[ "$(file -i --dereference $(git diff --name-only HEAD^..HEAD) | grep binary | grep -v 'image/' | grep -v 'inode/x-empty')" != "" ]]; then exit 1; fi -- 2.47.2