Skip to content

Commit 8a574f6

Browse files
committed
fix: resolve release_id for manual workflow dispatch
1 parent 69140d6 commit 8a574f6

File tree

1 file changed

+10
-0
lines changed

1 file changed

+10
-0
lines changed

.github/workflows/virustotal.yml

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -13,6 +13,16 @@ jobs:
1313
name: Scan Release Assets
1414
runs-on: ubuntu-latest
1515
steps:
16+
- name: Get latest release ID
17+
if: github.event_name == 'workflow_dispatch'
18+
id: release
19+
env:
20+
GH_TOKEN: ${{ github.token }}
21+
run: |
22+
RELEASE_ID=$(gh api repos/${{ github.repository }}/releases/latest --jq '.id')
23+
echo "id=$RELEASE_ID" >> "$GITHUB_OUTPUT"
24+
1625
- uses: cssnr/virustotal-action@v1
1726
with:
1827
vt_api_key: ${{ secrets.VT_API_KEY }}
28+
release_id: ${{ steps.release.outputs.id || '' }}

0 commit comments

Comments
 (0)