Skip to content

Commit b6ff4c3

Browse files
committed
pass runId
1 parent 6540cc3 commit b6ff4c3

File tree

2 files changed

+5
-1
lines changed

2 files changed

+5
-1
lines changed

.github/actions/restore-artifacts/action.yml

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -15,6 +15,9 @@ inputs:
1515
token:
1616
description: GITHUB_TOKEN from secrets (not accessible from here)
1717
required: false
18+
runId:
19+
description: The GITHUB_RUN_ID
20+
required: false
1821

1922
runs:
2023
using: composite
@@ -65,7 +68,7 @@ runs:
6568
rm -rf $(jq -r '.testToDelete' <<< $client) || true
6669
6770
# Get the artifact id
68-
id=$(gh api -H "Accept: application/vnd.github.v3+json" /repos/algolia/api-clients-automation/actions/runs/${{ env.GITHUB_RUN_ID }}/artifacts -q ".artifacts [] | select(.name==\"$artifact\") | .id")
71+
id=$(gh api -H "Accept: application/vnd.github.v3+json" /repos/algolia/api-clients-automation/actions/runs/${{ inputs.runId }}/artifacts -q ".artifacts [] | select(.name==\"$artifact\") | .id")
6972
gh api -H "Accept: application/vnd.github.v3+json" /repos/algolia/api-clients-automation/actions/artifacts/$id/zip > $artifact.zip
7073
unzip -q -o $artifact.zip && rm $artifact.zip
7174
done

.github/workflows/check.yml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -245,6 +245,7 @@ jobs:
245245
type: all
246246
matrix: ${{ toJSON(needs.setup.outputs.GEN_MATRIX) }}
247247
token: ${{ secrets.ALGOLIA_BOT_TOKEN }}
248+
runId: ${{ env.GITHUB_RUN_ID }}
248249

249250
- name: Setup
250251
uses: ./.github/actions/setup

0 commit comments

Comments
 (0)