3
0
Fork 0
mirror of https://github.com/dtolnay/install.git synced 2025-01-31 07:01:20 +01:00

Merge pull request #29 from dtolnay/ghtoken

Add input for custom gh token
This commit is contained in:
David Tolnay 2025-01-28 21:54:43 -08:00 committed by GitHub
commit 5db909af00
No known key found for this signature in database
GPG key ID: B5690EEEBB952194

View file

@ -8,6 +8,9 @@ inputs:
bin:
description: Name of binary; default = same as crate name
required: false
github_token:
description: Access token for connecting to GitHub API for artifact attestation; normally the ephemeral {{github.token}} when used in a GitHub workflow, or a personal access token {{secrets.GH_TOKEN}} in Gitea's act runner
default: ${{github.token}}
runs:
using: composite
steps:
@ -27,7 +30,7 @@ runs:
- name: Verify artifact attestation
run: gh attestation verify --owner dtolnay ${{steps.cargo.outputs.dir}}/${{steps.inputs.outputs.bin}}
env:
GH_TOKEN: ${{github.token}}
GH_TOKEN: ${{inputs.github_token}}
shell: bash
- name: Set executable bit
run: chmod +x ${{steps.cargo.outputs.dir}}/${{steps.inputs.outputs.bin}}