From e79947fa7918b70082272ce79ec3dcd7709cfd1f Mon Sep 17 00:00:00 2001 From: Sean Date: Fri, 16 Aug 2024 20:25:19 -0700 Subject: [PATCH] Safely pass comment JSON to script https://github.com/actions/github-script/issues/56#issuecomment-642188313 --- .github/workflows/comment.yml | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/.github/workflows/comment.yml b/.github/workflows/comment.yml index 52407ce..0ed303f 100644 --- a/.github/workflows/comment.yml +++ b/.github/workflows/comment.yml @@ -12,7 +12,9 @@ jobs: - uses: actions/checkout@v4 - run: npm install - name: Write to data/comments.yml - run: npx tsx dev/add-comment.ts '${{ toJson(github.event) }}' + env: + COMMENT: ${{ toJson(github.event) }} + run: npx tsx dev/add-comment.ts $COMMENT - name: Build run: npm run build - name: Upload artifact