From ccf4b5f41165a0d8ded9f8ed6f4dafa1640c83c7 Mon Sep 17 00:00:00 2001 From: Jon Peck Date: Thu, 13 Feb 2025 11:42:33 -0800 Subject: [PATCH] if triggered by push, use a default hardcoded ISSUE ID --- .github/workflows/cicd-pages.yml | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/.github/workflows/cicd-pages.yml b/.github/workflows/cicd-pages.yml index 6ee5136..d7df75f 100644 --- a/.github/workflows/cicd-pages.yml +++ b/.github/workflows/cicd-pages.yml @@ -33,8 +33,11 @@ jobs: steps: - name: Checkout uses: actions/checkout@v3 + - name: Set ISSUE_ID + if: github.event_name == 'push' + run: echo "ISSUE_ID=69" >> $GITHUB_ENV - name: Output Issue ID - run: echo ${{ github.event.inputs.ISSUE_ID }} + run: echo ${{ github.event.inputs.ISSUE_ID || env.ISSUE_ID }} - name: Setup Pages uses: actions/configure-pages@v1 - name: Set up node with nvm @@ -50,7 +53,7 @@ jobs: script: | const fs = require('fs') await github.paginate(github.rest.issues.listComments, - { owner: 'gh-event-demos', repo: 'random-name-picker', issue_number: ${{ github.event.inputs.ISSUE_ID }} }, + { owner: 'gh-event-demos', repo: 'random-name-picker', issue_number: ${{ github.event.inputs.ISSUE_ID || env.ISSUE_ID }} }, (response) => response.data.map((issuecomment) => issuecomment.user.login) ) .then((commenters) => {