File tree Expand file tree Collapse file tree 1 file changed +8
-6
lines changed
Expand file tree Collapse file tree 1 file changed +8
-6
lines changed Original file line number Diff line number Diff line change @@ -28,13 +28,15 @@ jobs:
2828 with :
2929 fetch-depth : " 0"
3030
31+ # We need to use `${{ ... }}` here to avoid `Argument list too long` error when a PR changes a lot of files.
32+ # (We could also try to use artifact approach, but it's more involved).
33+ # `CodeQL` doesn't identify any security issue here. Also `PR_FILES` is from `get-pr-info.yml` by using an api
34+ # `github.rest.pulls.listFiles`, which is fine.
3135 - name : Write pr_files file
32- uses : actions/github-script@v7
33- with :
34- script : |
35- const fs = require('node:fs');
36- const prFilesJson = `${{ needs.get-pr-info.outputs.PR_FILES }}`;
37- fs.writeFileSync('pr_files.txt', prFilesJson);
36+ run : |
37+ cat > pr_files.txt << 'EOF'
38+ ${{ needs.get-pr-info.outputs.PR_FILES }}
39+ EOF
3840
3941 - name : Get repository content
4042 id : repo_content
You can’t perform that action at this time.
0 commit comments