github-actions
7 commands
7 shown
Trigger workflow with inputs
Dispatch a workflow_dispatch run passing typed inputs; note: needs workflow_dispatch trigger
gh workflow run deploy.yml -f env=prod -f version=1.4.2 --ref main
Watch latest run live
Stream the newest run's progress live and exit with its status code
gh run watch $(gh run list -w deploy.yml -L1 --json databaseId -q '.[0].databaseId')
Show only failed logs
Print logs of failed steps only, skipping noise from passing jobs
gh run view <id> --log-failed | less -R
Run a job locally with act
Run an Actions job in Docker locally before pushing; note: pin a real runner image
act -j build --secret-file .secrets -P ubuntu-latest=catthehacker/ubuntu:act-22.04
Rerun only failed jobs
Retry just the failed jobs of a run, reusing prior successful results
gh run rerun <id> --failed
List and prune caches
Find the biggest Actions caches and delete stale ones to free quota
gh cache list --sort size_in_bytes --order desc; gh cache delete <id>
OIDC keyless cloud auth
Job-level perms enabling OIDC token to assume a cloud role without static keys
permissions:
id-token: write
contents: read
no commands match