add debug

This commit is contained in:
burnettk 2024-02-01 16:21:41 -05:00
parent d705a4146f
commit e1757afe10
No known key found for this signature in database

View File

@ -20,15 +20,15 @@ permissions:
jobs:
# uncomment this to print the context for debugging in case a job is getting skipped
# printJob:
# name: Print event
# runs-on: ubuntu-latest
# steps:
# - name: Dump GitHub context
# env:
# GITHUB_CONTEXT: ${{ toJson(github) }}
# run: |
# echo "$GITHUB_CONTEXT"
printJob:
name: Print event
runs-on: ubuntu-latest
steps:
- name: Dump GitHub context
env:
GITHUB_CONTEXT: ${{ toJson(github) }}
run: |
echo "$GITHUB_CONTEXT"
dependabot:
runs-on: ubuntu-latest
@ -44,14 +44,18 @@ jobs:
uses: actions/github-script@v6
with:
script: |
console.log("download artifact: started")
console.log("download artifact: content.payload: ", context.payload)
let allArtifacts = await github.rest.actions.listWorkflowRunArtifacts({
owner: context.repo.owner,
repo: context.repo.repo,
run_id: context.payload.workflow_run.id,
});
console.log("download artifact: got allArtifacts")
let matchArtifact = allArtifacts.data.artifacts.filter((artifact) => {
return artifact.name == "pr_number"
})[0];
console.log("download artifact: got matchArtifact: ", matchArtifact)
let download = await github.rest.actions.downloadArtifact({
owner: context.repo.owner,
repo: context.repo.repo,