gh run
Follow GitHub Actions runs and read their logs
What it does
gh run list shows the latest workflow runs: status, name, branch and event. gh run watch follows a run in progress step by step until it finishes; with no number it asks which one.
gh run view shows a run's details, and --log-failed just the log of the failed steps, without thousands of lines from the ones that passed. A failed run can be restarted: gh run rerun <number> --failed.
Syntax
gh run list
gh run watch
gh run view <number> --log-failed
gh run rerun <number> --failedExamples
List the latest GitHub Actions runs
gh run listrun— workflow runs in Actionslist— list with status and branch
Watch a running Actions run until it finishes
gh run watchrun watch— the run's steps live; asks which run
See the log of only the steps that failed in a run
gh run view --log-failedrun view— run details; asks which run--log-failed— the log of the failed steps only
Related commands
- gh pr checks — Check the CI status of a pull request
- gh workflow run — Start a GitHub Actions workflow by hand
- gh secret set — Add a secret for GitHub Actions