From e336f1b77e96fed98230bb851a30237cee255de0 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Viktor=20Sz=C3=A9pe?= Date: Sun, 8 Oct 2023 15:02:52 +0200 Subject: [PATCH 1/2] Add file name check --- .github/workflows/reusable-integrity.yml | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/.github/workflows/reusable-integrity.yml b/.github/workflows/reusable-integrity.yml index c5c457a..614d95f 100644 --- a/.github/workflows/reusable-integrity.yml +++ b/.github/workflows/reusable-integrity.yml @@ -45,6 +45,12 @@ jobs: - name: "Checkout repository" uses: "actions/checkout@v3.6.0" + - + name: "Check file names" + run: | + git ls-tree -r -t -z --name-only HEAD \ + | xargs -0 -n 1 -- basename \ + | grep -P '[^-.0-9A-Z_a-z]' - name: "Check file permissions" run: | From ff98203135fcfdabaa8c93e77dfd172f9a5306f4 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Viktor=20Sz=C3=A9pe?= Date: Sun, 8 Oct 2023 15:06:12 +0200 Subject: [PATCH 2/2] Update reusable-integrity.yml --- .github/workflows/reusable-integrity.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/reusable-integrity.yml b/.github/workflows/reusable-integrity.yml index 614d95f..8126957 100644 --- a/.github/workflows/reusable-integrity.yml +++ b/.github/workflows/reusable-integrity.yml @@ -48,7 +48,7 @@ jobs: - name: "Check file names" run: | - git ls-tree -r -t -z --name-only HEAD \ + ! git ls-tree -r -t -z --name-only HEAD \ | xargs -0 -n 1 -- basename \ | grep -P '[^-.0-9A-Z_a-z]' -