Skip to content

Commit 99623d3

Browse files
fix(security): remediate workflow vulnerability in .github/workflows/validate-blog-entries.yml
1 parent 092bf0d commit 99623d3

1 file changed

Lines changed: 7 additions & 2 deletions

File tree

.github/workflows/validate-blog-entries.yml

Lines changed: 7 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -19,9 +19,14 @@ jobs:
1919
- name: Get changed markdown files
2020
id: changed-files
2121
working-directory: .
22+
env:
23+
BASE_SHA: ${{ github.event.pull_request.base.sha }}
24+
HEAD_SHA: ${{ github.sha }}
2225
run: |
23-
FILES=$(git diff --name-only --diff-filter=AM ${{ github.event.pull_request.base.sha }} ${{ github.sha }} -- '*.md' | tr '\n' ' ')
26+
FILES=$(git diff --name-only --diff-filter=AM "$BASE_SHA" "$HEAD_SHA" -- '*.md' | tr '\n' ' ')
2427
echo "files=$FILES" >> $GITHUB_OUTPUT
2528
- name: Validate blog entries are listed in _blog.yml
2629
if: steps.changed-files.outputs.files != ''
27-
run: deno run --allow-read ./validate-blog-entries.ts ${{ steps.changed-files.outputs.files }}
30+
env:
31+
CHANGED_FILES: ${{ steps.changed-files.outputs.files }}
32+
run: deno run --allow-read ./validate-blog-entries.ts $CHANGED_FILES

0 commit comments

Comments
 (0)